What the SPF Checker looks at
SPF (Sender Policy Framework, RFC 7208) is a TXT record that lists the servers allowed to send mail using your domain in the envelope sender (the bounce address). The checker:
- Finds every TXT record starting with
v=spf1on the domain. - Parses each mechanism and modifier and flags syntax errors.
- Follows every
include,redirect,a,mxandexistsand counts DNS lookups against the limit of 10. - Counts void lookups: lookups that return no answer or a domain that doesn't exist.
- Checks the final
allqualifier. - Shows the full include tree so you can see where your lookups are spent.
How to read the results
- Pass. One valid SPF record, within the lookup limit, ending in
-allor~all. - Warning. Valid but risky. Examples: close to 10 lookups (one more vendor could break it),
?all(neutral, which protects nothing), aptrmechanism (RFC 7208 says not to use it), or one void lookup. - Fail. Receivers will get an error or the record is unsafe. Examples: more than 10 lookups, more than two void lookups, two SPF records, a syntax error, a
redirectto a domain without SPF, or+all. - Not tested. DNS didn't answer in time. Try again.
- Not applicable. The check doesn't apply to this domain. Even a domain that sends no mail should still publish
v=spf1 -all, so this status is rare.
What counts toward the limit
RFC 7208 section 4.6.4 lists the terms that cause DNS lookups: include, a, mx, ptr, exists and the redirect modifier. The total across the whole tree must not exceed 10, or the result is PermError. ip4, ip6 and all don't count.
Each mx mechanism can also look up at most 10 address records. A domain with more than 10 MX hosts will make mx return PermError.
How redirect works
redirect=_spf.example.com hands evaluation to another domain's SPF record. Two rules catch people out:
redirectis ignored if the record contains anallmechanism anywhere.- If the target has no SPF record, the result is PermError, not "none".
Common problems and fixes
Two SPF records. This often happens when a new service tells you to "add a TXT record". Merge them:
Wrong:
example.com. TXT "v=spf1 include:spf.protection.outlook.com -all"
example.com. TXT "v=spf1 include:mailer.example.net ~all"
Right:
example.com. TXT "v=spf1 include:spf.protection.outlook.com include:mailer.example.net -all"
Too many lookups. Remove services you no longer use, drop a and mx if those hosts don't send mail, and move bulk senders such as newsletters to a subdomain with its own SPF record. Our guide on fixing SPF PermError from too many DNS lookups walks through it.
Void lookups. An include pointing to a retired service often returns nothing. Delete it.
Using +all. This authorizes every server on the internet. Replace it with -all or ~all.
Domain that sends no mail. Publish:
example.com. TXT "v=spf1 -all"
Behind a filtering gateway
When inbound mail passes through a filtering service, the SPF check that matters is done by the filter, on the original sender. Your own SPF record only needs to list servers that send your outgoing mail. If you use an outbound relay, add the include value your relay provider gives you. iBlockSpam customers find theirs in the setup wizard.
Limitations
- SPF checks the envelope sender, not the From address people see. It's DMARC that ties SPF to the visible From domain.
- SPF usually breaks when mail is forwarded, because the forwarding server isn't in your record. That's expected; DKIM survives forwarding more often.
- We count lookups using today's DNS. Vendors change their own SPF records, so a record that passes today can go over the limit later without you touching it. Re-check after adding any sender.
- A Pass means your record is well formed. It doesn't prove that every server sending your mail is listed. Your DMARC reports show that.
Related
See SPF records by email provider for the exact include each service documents. Read SPF vs DKIM vs DMARC for how SPF fits with the other two, or run the full Email Health Check.
Frequently asked questions
What is the SPF 10 lookup limit?
RFC 7208 says SPF checks must stop after 10 DNS-querying terms: include, a, mx, ptr, exists and redirect. Going over returns PermError, which many receivers treat like a failed SPF check. ip4, ip6 and all don't count.
What is a void lookup?
A lookup that returns no records or a 'domain doesn't exist' answer. RFC 7208 recommends allowing at most two. More than that returns PermError. Old includes for services you no longer use are the usual cause.
What does an SPF PermError mean?
It's a permanent error: receivers can't evaluate your SPF record, so SPF can't pass. Common causes are two TXT records starting with v=spf1, more than 10 DNS lookups, or a syntax mistake. Merge duplicate records into one and fix the cause.
Why does the checker warn about ?all and +all?
?all (neutral) tells receivers nothing about unlisted servers, and +all authorizes every server on the internet to send as you. Use ~all (softfail) while you confirm every sender is listed, then -all (fail) once every sender is listed and DKIM-signed. With DMARC at enforcement and DKIM on every sender, receivers act on DMARC results.
Do I need SPF if I have DKIM?
Yes, publish both. Large mailbox providers such as Gmail and Yahoo require bulk senders to have SPF and DKIM, plus DMARC. SPF also lets a receiver check the envelope sender when there's no signature.
Related guides
What is SPF, and how does an SPF record work?
What an SPF record is, how receivers check it against the envelope sender, the 10-lookup limit, what SPF can't do, and how to create one for your domain.
9 min read SPF, DKIM & DMARCHow to fix SPF PermError: too many DNS lookups
Why SPF breaks at 10 DNS lookups, how to count them, and step-by-step fixes for Microsoft 365 and Google Workspace domains with many senders.
8 min read SPF, DKIM & DMARCSPF record syntax and examples
SPF record syntax explained: mechanisms, qualifiers and modifiers, with copy-ready examples for Microsoft 365, Google Workspace, subdomains and parked domains.
9 min read