The short version
SPFWas this server allowed?A list of the servers allowed to send for the domain in the Return-Path.What is SPF? →DKIMWas it signed, and unchanged?A signature proving which domain signed the message and that it wasn't altered.What is DKIM? →DMARCDoes it match the From address?Checks that SPF or DKIM passed for the domain people see, and says what to do if not.What is DMARC? →Side by side
| SPF | DKIM | DMARC | |
|---|---|---|---|
| Checks | The sending server's IP address | A signature on the message | That SPF or DKIM passed for the From domain |
| Domain it looks at | Return-Path (envelope sender) | The d= signing domain | From, the address people see |
| DNS record | TXT at the domain root | TXT or CNAME at selector._domainkey | TXT at _dmarc |
| Survives forwarding | No | Usually | Uses whichever still passes |
| Detects changes to the message | No | Yes | Through DKIM |
| Tells receivers what to do | Weakly, through -all or ~all | No | Yes: none, quarantine or reject |
| Sends you reports | No | No | Yes, daily |
| Main limits | One record, 10 DNS lookups | Each sending service needs its own setup | Needs SPF or DKIM aligned to pass |
How they work together
On their own, SPF and DKIM both have the same blind spot: they can pass for any domain. An attacker can set up SPF and DKIM perfectly for their own domain, then put yours in the From line. Both checks pass; neither looks at From.
DMARC closes the gap with one rule, called alignment: at least one of SPF or DKIM must pass for a domain that matches the From address. Then it adds what the other two lack: a policy telling receivers what to do with failures, and reports showing you everyone sending as your domain.
Four messages, four outcomes
| Message | SPF | DKIM | DMARC |
|---|---|---|---|
| Your own mail from Microsoft 365, DKIM on | Pass, aligned | Pass, aligned | Pass |
| Your mail, forwarded by a recipient | Fail | Pass, aligned | Pass |
| A newsletter tool without custom DKIM | Pass, for its domain | Pass, for its domain | Fail |
| A spoofed message using your domain | Fail | None | Fail |
The third row is the one that surprises people, and the most common reason legitimate mail fails DMARC. See why third-party email fails DMARC.
What to set up first
- SPF for every domain that sends, and
v=spf1 -allfor those that don't. - DKIM on your mail platform and in every service that sends as you.
- DMARC at
p=nonewith a reporting address, then read the reports. - Enforce: quarantine, then reject. See moving from p=none to reject.
Common questions
#Do I need all three?
Yes. SPF and DKIM prove where a message came from; only DMARC connects that proof to the From address and tells receivers what to do when it fails. Large mailbox providers now expect all three from anyone sending in volume.
#Is SPF or DKIM enough for DMARC to pass?
Either one is enough, as long as it passes for a domain that matches the From address. Setting up both gives you a fallback when one breaks, for example SPF on forwarded mail.
#Which should I set up first?
SPF and DKIM, then DMARC at p=none. DMARC can't pass without at least one of the other two.