Why your emails go to spam: SPF, DKIM and DMARC in plain words
Last checked
In short
Before a mail server trusts a message from your domain, it checks three DNS records. SPF says which servers may send for you, DKIM proves a message was not altered, and DMARC says what to do when both fail. If any is missing or wrong, your mail looks forged and is filed as spam.
Check the domain with an email security checker, fix what it flags, and send a test message to a Gmail address to confirm all three pass.
The three records
- SPF is a TXT record on your domain listing the services allowed to send mail as it: your mail provider, your newsletter tool, your invoicing system. Mail from a server not on the list fails SPF.
- DKIM is a signature each sending service adds to every message, checked against a public key you publish in DNS. It proves the message came from a system holding your key and was not changed on the way.
- DMARC is a TXT record at _dmarc.yourdomain that tells receivers what to do with mail that fails both - deliver it, send it to spam, or refuse it - and where to send reports.
The mistakes that cause most of it
- A sending service is missing from SPF. You added a newsletter or helpdesk tool and never added its include to the record. Its mail fails SPF.
- Two SPF records. A domain may have only one record starting v=spf1. Two, often left from switching providers, make receivers ignore both.
- SPF needs more than ten DNS lookups. Every include counts, and so do the includes inside it. Past ten, receivers treat the whole record as broken - for all your mail.
- DKIM was never switched on. Most providers sign mail only after you add their DKIM record to your DNS and press a button in their settings.
- No DMARC record at all. Large providers now expect one, and treat mail from a domain without it with more suspicion.
- The From address is on a different domain from the one that passed. DMARC requires the domain people see to match the one SPF or DKIM vouched for.
What Gmail, Yahoo and Outlook require
Since 2024 Gmail and Yahoo require every sender to have SPF or DKIM, and anyone sending around 5,000 messages a day to their users to have SPF, DKIM and a DMARC record, with a one-click unsubscribe link in marketing mail and a low complaint rate. Microsoft introduced similar rules for Outlook addresses in 2025.
Even well below those volumes, having all three in place is what separates mail that is delivered from mail that is guessed at.
Fix it in this order
- List every service that sends mail as your domain. This is the step people skip, and it is where the missing include is found.
- Publish one SPF record that names them all, ending in ~all. Count its lookups and stay under ten.
- Turn on DKIM in each service and add the record it gives you.
- Publish a DMARC record with p=none and a rua= address for reports. This changes nothing about delivery and shows you who is sending as you.
- Read the reports for two or three weeks. When your own mail all passes, move to p=quarantine, and later to p=reject.
Check that it worked
Send a message to a Gmail address, open it, and choose “Show original”. Gmail shows SPF, DKIM and DMARC with PASS or FAIL beside each. All three should pass.
DNS records are only part of deliverability. Content, links, complaint rates and a new domain's lack of history all count too. But authentication is the part that is either right or wrong, and it comes first.
Keep it right
These records break without anyone meaning to break them: a new tool edits SPF, a DNS move drops a DKIM key, a provider changes its own includes and pushes you past ten lookups. Having the domain graded on a schedule, with an alert when the grade drops, catches that before your customers' spam folders do.