SPF fail in a DMARC report when the header says pass
Updated
You open a message from your own system, and the header says spf=pass. Then the DMARC report for the same day says SPF failed for that sender. Both are correct. The header and the report answer different questions, and often they are not even about the same delivery.
The report has two SPF results
Every record in an aggregate report mentions SPF twice:
<row>
<source_ip>203.0.113.25</source_ip>
<count>412</count>
<policy_evaluated>
<disposition>none</disposition>
<dkim>pass</dkim>
<spf>fail</spf>
</policy_evaluated>
</row>
<identifiers>
<header_from>example.com</header_from>
<envelope_from>bounces.example.org</envelope_from>
</identifiers>
<auth_results>
<spf><domain>bounces.example.org</domain><scope>mfrom</scope><result>pass</result></spf>
</auth_results>
auth_results/spfis the SPF check itself: was this IP allowed to send for the return-path domain (envelope_from)? Here: yes, forbounces.example.org.policy_evaluated/spfis the DMARC view: did SPF pass for a domain that matches the From: domain? Here: no, becausebounces.example.orgis notexample.com.
The header on the message is the first of these. It looks like this:
Authentication-Results: mx.example.net;
spf=pass smtp.mailfrom=bounces.example.org;
dkim=pass header.d=example.com;
dmarc=pass header.from=example.com
spf=pass there says only that SPF passed for the domain after smtp.mailfrom=. Many report tools show the policy_evaluated value in their "SPF" column, so the same mail reads "pass" in the header and "fail" in the tool.
Which case you have
Find the record for the sender in the report and compare envelope_from, header_from and the two results.
| In the record | What it is | What to do |
|---|---|---|
auth_results SPF pass, envelope_from is another domain than header_from | SPF passed for the sending service's bounce domain. Not aligned. | Nothing, if policy_evaluated/dkim is pass. See below. |
auth_results SPF fail or softfail, envelope_from is your domain, source_ip is not one of yours | Forwarding. The header you read was from the direct delivery, the record is a forwarded copy. | Nothing. See Forwarding. |
auth_results SPF pass, envelope_from is a subdomain of header_from, aspf is s in policy_published | Strict alignment. A subdomain return-path only counts in relaxed mode. | Decide whether you need aspf=s. |
auth_results SPF domain is a server name, envelope_from is empty | A bounce or auto-reply with an empty return-path. SPF was checked against the server's HELO name. | Nothing. These need DKIM to pass DMARC. |
Result and alignment
DMARC only counts an SPF pass when the return-path domain matches the domain in From:. In relaxed mode, the default, a subdomain is enough: bounces.example.com matches example.com. In strict mode (aspf=s) the two must be identical.
Most email services use their own bounce domain as return-path unless you set up a custom one. SPF then passes for their domain, which says nothing about yours, and the report shows fail under policy_evaluated. Adding the service's include: to your SPF record does not change this, because your SPF record is not the one being checked.
How to make SPF align for a service, with the record to publish, is on Lookproof's page SPF passes but DMARC fails.
Forwarding
The header you looked at came from one message, delivered once. A report record adds up many deliveries, and some reach the reporting receiver through a forwarder: an old address that forwards to a new mailbox, a school or alumni alias, a shared address that fans out.
The forwarder keeps your return-path but connects from its own IP. That IP is not in your SPF record, so the SPF check itself fails, with your domain as envelope_from. These show up as separate records with small counts and source IPs you do not know. The record for your real sending IP, with the large count, still shows what the header showed.
You cannot fix SPF for forwarded mail, and should not try by widening your SPF record. A DKIM signature usually survives forwarding, and that is what carries DMARC for these messages. To tell forwarders from other unknown rows, see Why DMARC reports show sources you don’t recognise.
When the SPF fail matters
DMARC passes when either SPF or DKIM passes with alignment. So read the two policy_evaluated values together:
dkimpass,spffail: DMARC passed. This is the normal state for mail through an email service and for forwarded mail. No action needed.dkimfail,spfpass: DMARC passed, but only on SPF. Every forwarded copy of this mail will fail. Set up DKIM with your domain at that service before moving top=reject; the DMARC specification requires domains atp=rejectnot to rely on SPF alone.- Both fail, from a service you use, with real volume: this mail fails DMARC. Fix DKIM at the service first, then SPF alignment if the service supports a custom return-path.
- Both fail, small counts, unknown IPs: forwarding of unsigned mail, a mailing list, or spoofing.
Comparing a header with a report
- Take the IP from the
Received:orReceived-SPF:header of the message and find the record with thatsource_ip, in the report from the receiver that added the header. - Check that the report's
date_rangecovers the day the message was received. The range is in UTC. - Compare
smtp.mailfromin the header withenvelope_fromin the record. If they match, the header's SPF result is the one underauth_results. - If no record has that IP, the record you were looking at is a different path for the same mail, usually a forwarder.
For every field in the report, see How to read DMARC aggregate reports.
Senderward checks your domain's DMARC, SPF, DKIM, MX, MTA-STS and TLS-RPT every day and emails you, with the fix, when something gets worse. $7 per domain per month, 14 days free. See pricing