Jason Baker Jason Baker - 1 year ago 109
Python Question

How do I send attachments using SMTP?

I want to write a program that sends email using Python's smtplib. I searched through the document and the RFCs, but couldn't find anything related to attachments. Thus, I'm sure there's some higher-level concept I'm missing out on. Can someone clue me in on how attachments work in SMTP?

Answer Source

What you want to check out is the email module. It lets you build MIME-compliant messages that you then send with smtplib.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download