Gmail To Send Email By Python Script

python

Posted by indranil on Feb. 17, 2021, 10:44 a.m.

Comming Soon

 

import smtplib
server = smtplib.SMTP('smtp.gmail.com', 587)
server.ehlo()
server.starttls()
server.login('your_email@gmail.com', 'your_password')
to = "example@emaple.com"
content = "My content for email"
server.sendmail('your_email@gmail.com', to, content)
server.close()
print("Email Has Been Send")

noimg Visit Link: digitalocean.com