Skip to content

SPF vs DKIM vs DMARC: the difference explained

By 4 min read

Line drawing for the post: SPF vs DKIM vs DMARC: the difference explained

SPF, DKIM, and DMARC are three DNS records that let a mail server check whether an email really comes from the domain in its From line. SPF checks the sending server, DKIM the message’s signature, and DMARC ties both to the visible sender and tells the receiver what to do when a check fails.

They do not replace each other, they build on each other. Set up only one and much of your mail still lands in spam.

The comparison at a glance

Criterion SPF DKIM DMARC
Checks May this server send for the domain? Is the message signed and unaltered? Do SPF or DKIM pass for the From domain?
DNS record TXT on the domain TXT at selector._domainkey TXT at _dmarc
Who sets it up You, for every service that sends Your mail provider; you publish the key You
Typical failure A new service sends, nobody adds it Signing never switched on at the provider Policy stuck at p=none
Enough on its own? No No No, needs SPF or DKIM

SPF lists who may send

Sender Policy Framework (SPF) is a list of the servers allowed to send mail on behalf of your domain. When a message arrives, the receiver checks whether the sending server is on the list.

The list grows with every service: Microsoft 365 or Google Workspace, plus the newsletter tool, the shop, the CRM, the invoicing software. Two limits cause most failures: only one SPF record per domain is allowed, and it may trigger at most ten DNS lookups (RFC 7208). Every include: counts.

DKIM signs every message

DomainKeys Identified Mail (DKIM) attaches a digital signature to every outgoing message. You publish the matching public key in DNS under a name called the selector. The receiver uses it to check that the message was really signed by your domain and not altered on the way.

Unlike SPF, DKIM survives forwarding. The most common failure: the mail provider offers DKIM, but nobody switched it on.

DMARC decides what happens on failure

Domain-based Message Authentication, Reporting and Conformance (DMARC) is the rule above both. It requires SPF or DKIM to pass, and to pass for the same domain the reader sees in the From line. That match is called alignment. DMARC also sets what happens to mail that fails:

Policy Effect
p=none Monitor only, mail is delivered
p=quarantine Failing mail goes to spam
p=reject Failing mail is refused

Through the address in rua, receivers send daily reports on which servers send in your name. Without these reports you don’t know which service would fail before you tighten the policy.

Why mail lands in spam despite a green SPF

The most common case: your newsletter tool sends with its own domain as the technical sender. SPF passes, but for the tool’s domain, not yours. DMARC doesn’t count that, because it doesn’t align. Only when the tool signs with your domain (DKIM) or sends from a subdomain of yours does DMARC pass too.

The fix is almost always the same: list every service that sends as your domain, set up DKIM with your domain for each, clean up SPF.

What Gmail, Yahoo, and Outlook require

Since February 2024, Google and Yahoo require senders who send more than 5,000 messages a day to their mailboxes to have SPF, DKIM, and an aligned DMARC record. Microsoft followed for Outlook.com in May 2025. Smaller senders face softer rules, but the filters use the same signals: a domain without DMARC loses the benefit of the doubt.

How to check all three at once

Our free email setup check reads SPF, DKIM (across the common selectors), DMARC, MX, MTA-STS, and BIMI in one pass and sorts the failures by what they cost. More checkers side by side are in the best free DMARC checkers.

FAQ

Do I need all three? Yes. SPF and DKIM prove the origin, DMARC ties them to the visible sender and protects your domain from strangers sending in your name.

Which DMARC policy should I start with? p=none with a rua address. Read the reports for two to four weeks, fix every sending service, then move to p=quarantine, later p=reject.

What happens with two SPF records? SPF fails outright. Merge all services into one record.

Does DMARC stop phishing with my domain? Yes, once the policy is quarantine or reject. At p=none you only see the abuse in the reports.

If many of your systems send mail, the problem is familiar from twelve tools and no time: inventory first, then order.

Contact

What eats your team's time?

Two or three sentences are enough. Philipp reads every message himself and usually replies within two business days.

Philipp Kant

Philipp Kant
Software & AI Architect, Krefeld

What is it about?

Opens your email app with the message to philipp@kant.dev, ready to send. You see everything before it goes out. Privacy policy

  • No sales call unless you ask for one.
  • No newsletter, no automated follow-ups.
  • Your message goes to one inbox: philipp@kant.dev.

Rather talk? Pick a 30-minute slot

Or write directly: philipp@kant.dev