SPF check: permitted senders for your domain
We read your domain's SPF record, count DNS lookups up to the limit of 10 and check the ending (~all, -all), DKIM and DMARC.
What the SPF check tests
- One record. Exactly one TXT record with v=spf1 on the domain. Two records count as none (permerror).
- 10 DNS lookups. Each include, a, mx, ptr, exists and redirect costs one lookup, including nested includes. Above 10, SPF fails.
- The ending. ~all marks other servers as suspicious, -all makes them fail; the receiver decides what happens to the mail. +all lets anyone send in your name.
Cutting too many lookups
- Remove old senders. A former newsletter tool or shop often stays in the record. Removing an include saves all lookups listed for it in the table.
- Replace a and mx. If you send mail from fixed addresses, replace a and mx with ip4: or ip6: using those addresses. ip4 and ip6 cost no lookup.
- Move tools to a subdomain. Many newsletter and invoicing services can send from news.your-domain or similar. Their SPF record then belongs to the subdomain and does not count for the main domain.
- Careful with flattening. Replacing includes with their IP addresses lowers the count but breaks when the provider changes its addresses. This requires regular updates.
All email records at once: email check. Single checks: DMARC check, SPF check, SPF lookup limit, MTA-STS check, DMARC generator.
Questions
What is an SPF record?
A TXT record on your domain listing the servers allowed to send mail for it (RFC 7208), for example v=spf1 include:_spf.google.com ~all. Receiving servers compare the sending server against it.
~all or -all?
~all (softfail) is the usual start: other mail is marked, not rejected. Use -all (fail) once every sender is confirmed as listed. With DMARC, its policy decides.
I have two SPF records, what now?
Merge them into one: one v=spf1, all parts of both records (include, ip4, ip6, a, mx) in a row, one ~all at the end. The check shows the merged record to copy.
How many includes may an SPF record have?
Total DNS lookups are limited to at most 10; the include count has no separate limit. One include can trigger more lookups; the check shows the count for each.
Does a domain without mail need SPF?
Yes: v=spf1 -all says nobody sends for it. Together with v=DMARC1; p=reject at _dmarc, the domain is closed to forged senders.