Skip to content
CCM Tools

SPF Generator & Analyzer

Generate and analyse SPF records, with presets for Google, Microsoft 365 and other providers.

SPF configuration

Quick presets
Adds the provider's include domains. Stack as many as the domain actually sends through.
One domain per line, added as include: mechanisms. A pasted "include:" prefix is stripped for you.
Mechanisms
One address or CIDR range per line.
One address or range per line.
Start on ~all while you confirm every sender is covered, then tighten to -all.

Generated SPF record

Record typeTXT
Host / name@ (or the domain itself)
TTL3600 (1 hour is plenty)
Your SPF record will appear here…

SPF quick reference

Qualifiers

  • + Pass — allow (the default when none is written)
  • - Fail — reject
  • ~ SoftFail — accept but mark suspicious
  • ? Neutral — no policy at all

Common mechanisms

  • include: Pull in another domain's SPF record
  • a Match the domain's A record IPs
  • mx Match the domain's MX host IPs
  • ip4: / ip6: Match specific addresses or ranges
Ten lookups is the hard ceiling. include:, a, mx, ptr, exists: and redirect= each cost one — and so does every one of those inside every record you include. Go over and receivers return PermError and stop evaluating SPF altogether. ip4: and ip6: cost nothing, so they are the way out of a crowded record.

SPF record input

The complete TXT value, including the v=spf1 prefix.
Examples to try

Analysis results

Nothing analysed yet

Paste a record on the left and hit Analyse to see the breakdown.