What SPF does
SPF (Sender Policy Framework) lists the servers allowed to send email for a domain. Receivers compare the sending server with this list.
Common SPF mistakes
- Two SPF records instead of one, which causes a permanent error.
- More than 10 DNS lookups from include, a, mx, ptr, exists and redirect.
- Ending with
+all, which lets anyone send as you. - Forgetting a service such as your CRM or newsletter tool.
Choosing the ending
~all (softfail) is a safe start. Move to -all (fail) once you are sure every legitimate sender is listed, and pair SPF with DKIM and DMARC.
Worked example
A typical record looks like v=spf1 include:_spf.google.com include:sendgrid.net -all. It says: Google and SendGrid may send for this domain, and everything else should fail. Each include costs DNS lookups, and SPF allows at most 10. Going over that limit makes the whole record fail with a permerror.
Common mistakes
- Publishing two SPF records. There must be exactly one TXT record that starts with v=spf1.
- Going over the 10 DNS lookup limit by adding includes for every tool you have ever used.
- Ending with +all, which allows the whole internet to send as you.
Where the results come from
Every lookup is made live at the moment you press the button, using DNS over HTTPS through Cloudflare's public resolver (1.1.1.1). Results are not cached on our side for longer than a few minutes, so a change you just made may still be hidden by the record's TTL elsewhere on the internet. The TTL shown with each record is the number of seconds other resolvers are allowed to keep the old value.
If you just changed a record and do not see it here yet, wait at least the old TTL and check again. Most changes are visible everywhere within an hour.
Privacy
Nothing you type into this tool is stored. Lookups are sent to DNS and the result is shown to you, then forgotten. There is no account and no history.
Who uses the spf checker
Domain owners adding a new email service, marketers checking deliverability before a campaign, and consultants auditing a client's setup.
How to use the spf checker, step by step
- Enter your domain, not a subdomain, unless you send from that subdomain.
- Read the record and the list of included services.
- Check that every service that sends for you appears.
- Confirm the record ends in ~all or -all.
Reading the results
| If you see | It means |
|---|---|
| No SPF record | Receivers cannot verify your senders; add one |
| More than one SPF record | Invalid; merge them into one |
| Ends in ?all or +all | Too permissive; use ~all or -all |
| Many includes | Watch the 10 DNS lookup limit |
Terms used on this page
- SPF
- Sender Policy Framework, a DNS record listing which servers may send mail for a domain, helping receivers detect spoofing.
- DNS
- The Domain Name System, which translates domain names into the information computers need, like IP addresses and mail servers.
- DKIM
- DomainKeys Identified Mail, a cryptographic signature added to emails so receivers can verify they weren't altered and came from the domain.
- DMARC
- A policy that tells receivers what to do with mail failing SPF or DKIM checks, and where to send reports.
- TXT record
- A DNS record that holds free-form text, used for SPF, DKIM, DMARC and domain verification.
- TTL
- Time to live, the number of seconds a DNS answer may be cached before it must be fetched again.
Related guides
Related free tools
- MX Lookup: See which servers receive email for any domain, live from DNS.
- SPF Checker: Validate SPF, spot multiple records and estimate DNS lookups.
- DMARC Checker: See any domain's DMARC policy and what it means.
- DKIM Checker: Fetch a DKIM public key by domain and selector.
FAQ
Does SPF check the From address?
No. SPF checks the envelope sender (Return-Path). DMARC is what connects the result to the visible From address.
Is the lookup count exact?
Our checker counts the mechanisms in the top-level record. Nested includes add more, so treat a count close to 10 as a warning.
Where do I add an SPF record?
As a TXT record on your domain at your DNS host, such as your registrar or Cloudflare.
How long until changes show?
Usually minutes, but up to the old record's TTL.