ShipBastion / Security guides / Fix the SPF 10 DNS lookup limit (PermError)
Fix the SPF 10 DNS lookup limit (PermError)
RFC 7208 allows at most 10 DNS-querying mechanisms when a receiver evaluates SPF. Go over and the result is PermError: SPF fails for every message, and DMARC can only pass through DKIM.
Free scan. Sign in with Google to see the full report; paid plans start with a 7-day free trial.
What counts as a lookup
include, a, mx, ptr, exists and redirect each count, recursively: an include that itself contains three includes costs four. ip4, ip6 and all cost nothing. Duplicate includes count every time they are evaluated.
dig +short TXT yourdomain.com | grep spf1 dig +short TXT _spf.google.com
Fix 1: remove what you no longer use
Old newsletter tools, a CRM you cancelled, a support desk that now sends from its own domain: each include is often 1 to 4 lookups.
Fix 2: move bulk senders to a subdomain
Send marketing from news.yourdomain.com with its own SPF record. Each hostname gets its own 10-lookup budget, and your main domain's reputation is isolated.
news.yourdomain.com. TXT "v=spf1 include:sendgrid.net -all"
Fix 3: flatten
Replace includes with the ip4/ip6 ranges they resolve to. This costs zero lookups but goes stale when the provider changes IPs, so re-generate it automatically. InboxShield's free SPF flattener produces the TXT, BIND zone or Cloudflare JSON output.
Try it on your own domain
Free scan, no card. Pro is $19/mo after a 7-day free trial and covers all four scanners: VibeShield, CiteReady, InboxShield and BrandShield.
FAQ
What happens when SPF exceeds 10 lookups?
Receivers return PermError, which DMARC treats as an SPF fail. Mail can still pass DMARC through aligned DKIM, but you lose the SPF path.
Does the void-lookup limit matter too?
Yes. More than two lookups that return no answer also cause PermError under RFC 7208.
Related
Move DMARC from p=none to p=reject without losing mail
A safe DMARC migration plan: collect rua reports at p=none, fix SPF and DKIM alignment for every sender, step through quarantine with pct, a...
InboxShield vs EasyDMARC
InboxShield vs EasyDMARC: $19/mo vs $44.99-$89.99/mo. SPF flattening, 91-selector DKIM sweep, 20 DNS blacklists, email header analyzer and D...
InboxShield vs MXToolbox
InboxShield vs MXToolbox: one scan covers MX, SPF lookup count, 91 DKIM selectors, DMARC, MTA-STS, TLS-RPT, BIMI/VMC and 20 blacklists with ...