Domain does not designate the IP as permitted sender

Quick fix

Add the sending service's include:, or ip4: for your own server, to your one SPF record before all.

v=spf1 include:_spf.google.com ip4:192.0.2.1 ~all

How to fix it

  1. Find the client-ip and the envelope sender domain in the Received-SPF or Authentication-Results header.
  2. Identify the server or service that uses that address. If it is forwarded mail, the fix is DKIM, not SPF.
  3. Add the service's include: from its documentation, or ip4:/ip6: for your own server, to the one SPF record, before all, for example v=spf1 include:_spf.google.com ip4:192.0.2.1 ~all.
  4. Count the lookups again: the record may use at most ten.

Learn more: SPF explained: lookups, includes and all

How to check

Take the domain after domain of from the header and check its record with the SPF check. The SPF flattener lists every address the record authorizes, so you can see whether the client-ip from the header is among them.

The SPF check opens with your domain filled in; it runs when you press Check.

Tools to check it

What the error means

Received-SPF: fail (... domain of [email protected] does not designate 192.0.2.1 as permitted sender)

"Does not designate ... as permitted sender" is the text receivers put in the Received-SPF header, and often in a bounce, when the IP address that delivered a message is not authorized by the SPF record of the envelope sender's domain. RFC 7208 section 9.1 shows the header like this: "Received-SPF: fail (mybox.example.org: domain of [email protected] does not designate 192.0.2.1 as permitted sender)". With ~all at the end of the record the result word is softfail instead of fail; the rest of the text is the same.

The header names the two things that were compared: the domain after domain of (the envelope-from, the address in the SMTP MAIL FROM) and the client-ip, the address that connected. RFC 7208 section 2.6.4: "A "fail" result is an explicit statement that the client is not authorized to use the domain in the given identity." A softfail is "a weak statement by the publishing ADMD that the host is probably not authorized".

The usual causes are a new mail service or server that was never added to the record, a server whose address changed, and forwarding: a forwarder delivers from its own address with your domain still in the envelope (see Email forwarding and DMARC). Microsoft's troubleshooting page gives the fix for the first cause: "When you add a new email service (for example, a customer relationship management (CRM) platform or marketing tool), add its SPF include to your record." A domain has one SPF record; Google: "Each domain can have one SPF record, but the record can specify additional servers and third parties that are allowed to send email from your domain."

Sources

All findings