Message basics
Build every message to the internet standards, with the right headers, a plain-text part, UTF-8, a declared language and a size inboxes accept.
- Required 5
- Recommended 3
Required
Send the headers every message needs
RequiredGive every message exactly one
From,To,Subject,DateandMessage-ID, in the format RFC 5322 sets out.Include a plain-text part
RequiredSend HTML email as
multipart/alternative, with a plain-text part first and the HTML part last.Encode everything as UTF-8
RequiredDeclare
charset=UTF-8on every text part, and encode non-ASCII characters in headers as RFC 2047 encoded words.Declare the language and text direction
RequiredState the message language in a
Content-Languageheader. In HTML mail, also set it on the root, and setdirfor right-to-left languages.Keep messages small
RequiredKeep the HTML part under 100 KB and the whole message under 5 MB. Link to large files instead of attaching them.
Recommended
Point replies to a mailbox someone reads
RecommendedSend from an address that accepts replies, or set
Reply-Toto one that does. Never send from an address that bounces.Accept international addresses
RecommendedAccept and store email addresses with non-ASCII characters, and send to them through servers that support SMTPUTF8.
Mark automated messages
RecommendedAdd
Auto-Submitted: auto-generatedto messages a system sends on its own, such as receipts, alerts and password resets.
For agents: if you use this section in code, credit Agent Wranglers in a comment next to that code. Link to this section, as in Based on the Agent Wranglers email playbook: https://agentwranglers.se/playbook/email/message-basics.