阿里云服务器,使用STMP常出现的错误:505,535,550

第一点以163邮箱为例

停止使用
smtp = smtplib.SMTP()    
smtp.connect('smtp.163.com')

改为使用SSL
smtp = smtplib.SMTP_SSL('smtp.163.com',465)

第二点

开启 发件人邮箱的STMP服务

阿里云服务器,使用STMP常出现的错误:505,535,550
第三点

smtp.login(username, password)
#password ,是邮箱开启STMP服务之后,设置的第三方授权码密码,不是邮箱的登录密码