Build a new SPF TXT record from common email providers, or paste an existing record to see a breakdown of mechanisms, DNS lookup count, syntax issues, and common SPF mistakes. Includes presets, migration guidance, and shareable URL state.
Tick the email services you use, add custom mechanisms if needed, choose a final policy. The record updates live.
include: mechanism to your record.ip4:<value>.
Add this as a TXT record on the root of your domain (or as SPF on legacy DNS hosts).
v=spf1 ~all
TXT record on the root of your domain (host = @ or empty).nslookup -type=TXT yourdomain.com or dig +short TXT yourdomain.com.
Paste a v=spf1 string (e.g. from dig TXT). It analyses live as you type.
Paste an SPF record on the left to see a breakdown.
| # | Qualifier | Mechanism | Value | What it does |
|---|
~all to -all safelyGoing from soft fail to hard fail without breaking legitimate email.
~all first. Soft fail still gets your email delivered while you observe.p=none; rua=mailto:reports@yourdomain.com. Reports tell you which sources send as your domain.-all. Now hard fail. Unauthorised senders are explicitly rejected.p=none → p=quarantine → p=reject over weeks, not days.The five errors that cause most SPF failures in production.
PermError and reject. Always keep exactly one v=spf1 TXT record per domain.
include:, a, mx, exists, and redirect= counts. Worse, include is recursive — a single include can pull in many sub-lookups. Crossing 10 causes PermError and SPF fails entirely.
+all
Allows the entire internet to send as your domain. Spammers love it. Never use it in production, even temporarily.
-all.
Return-Path header, which the user never sees. Spoofers forge the visible From: header, which SPF doesn't protect. Always pair SPF with DKIM and DMARC.