Skip to content

Instantly share code, notes, and snippets.

@fmasanori
Created February 9, 2013 13:23
Show Gist options
  • Save fmasanori/4745299 to your computer and use it in GitHub Desktop.
Save fmasanori/4745299 to your computer and use it in GitHub Desktop.
Gmail Send Message
import smtplib
usr = 'your_user@gmail.com'
pwd = 'your password'
dst = 'destination email'
server = smtplib.SMTP('smtp.gmail.com:587')
server.starttls()
server.login(usr, pwd)
server.sendmail(usr, dst, 'Python Rocks!')
server.quit()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment