Ruvalin

Definition

SPF

Sender Policy Framework

SPF is a DNS TXT record listing the servers permitted to send email for a domain name, which the receiving server compares against the IP address the connection is arriving from.

SPF checks an identity your recipient never sees: the Envelope-From, the return address used during the SMTP conversation. This is why SPF alone does not stop impersonation: a fraudster can pass SPF perfectly well on their own domain while displaying yours in the field a human reads.

A record ends with a qualifier saying what to do about everyone else: -all (hard fail), ~all (soft fail) or ?all (neutral). Its least-understood constraint is the ten-DNS-lookup limit, beyond which evaluation returns permerror and the record stops protecting anything.

An SPF record for a domain served by Google Workspace
example.com.  IN  TXT  "v=spf1 include:_spf.google.com -all"
Also known as
SPF, SPF record, Sender Policy Framework, v=spf1
Standard
RFC 7208

See also

In the guides

The whole glossary

CallBook