An email arrives with SPF: PASS in the headers. A few lines below, DMARC: FAIL appears. It looks contradictory, but the two results answer different questions.

SPF asks whether the sending server was authorised to send for the envelope sender's domain. DMARC asks whether at least one successful SPF or DKIM result also aligns with the domain people see in the From address.

Both SPF and DKIM can pass for another company's domain while DMARC fails for yours. This is particularly common with email platforms, forwarding and misconfigured custom sending domains.

The fastest way to understand the problem is to compare three domain names—not to add another random include to your SPF record.

The three domains that matter

Look at these parts of a receiving mail server's authentication report:

  • From / header.from: the domain visible in the sender's address. DMARC evaluates alignment against this identity.
  • smtp.mailfrom / Return-Path: the envelope sender's domain. SPF can pass for this domain even if the visible From uses a different one.
  • DKIM header.d: the domain used to sign the email. A passing DKIM signature helps satisfy DMARC only when the signing domain aligns with the visible From.

The names don't have to be character-for-character identical in every setup. DMARC supports relaxed alignment, which can allow subdomains under the same organisational domain, and strict alignment, which requires an exact match. The domain's DMARC policy determines the alignment mode.

Microsoft's email authentication troubleshooting guide covers this same distinction, including why an SPF pass can coexist with a DMARC failure.

Read an example without guessing

The following is an illustrative example, not the header of a real email.

From: Support <support@company.example>
Return-Path: <bounce@mailer.example>
Authentication-Results: mail.receiver.example;
  spf=pass smtp.mailfrom=mailer.example;
  dkim=pass header.d=mailer.example;
  dmarc=fail header.from=company.example

At first glance, it seems healthy: two green passes.

Now compare the domains:

  • Visible From: company.example
  • SPF-authenticated MAIL FROM: mailer.example
  • DKIM signing domain: mailer.example

The sending platform has authenticated its own domain. Neither passing identity aligns with company.example, so those passes do not satisfy DMARC for the visible From domain.

The fix might be to configure the provider to sign mail using the company's domain, or to configure an aligned custom MAIL FROM domain where the provider supports it. It is not automatically a reason to weaken your DMARC policy.

Microsoft documents the domain-alignment troubleshooting process, including examples where SPF and DKIM each pass for a different domain.

How to find these results in Gmail or Outlook

Gmail: Open the message, use More → Show original, then look for the authentication results. Copy the header block if you want a structured reading of its claims.

Outlook: Depending on whether you're using classic Outlook, new Outlook or Outlook on the web, open the message's properties or message-source view to inspect the headers. The precise menu differs by version.

ArsKhan's Email Header Analyzer reads pasted headers locally in your browser. It groups reported SPF, DKIM, DMARC and ARC claims, shows the reported authorities, and lays out the Received hops and timing.

There is one crucial limit: the analyzer does not perform DNS lookups or verify cryptographic signatures. A line in pasted text claiming dkim=pass is still only a claim. Use the receiving provider's trusted results for real verification; don't accept a header copied from an untrusted source as proof.

Headers can contain names, addresses, IP addresses and internal mail infrastructure. Remove sensitive details if you don't need them for the diagnosis, and only inspect messages you are authorised to use.

Why forwarded mail can fail SPF

Forwarding is another common source of confusion.

Suppose a message travels from its original sender to a forwarding service and then to your inbox. SPF is based on the connecting sending server. When that server changes, the original sender's SPF authorisation may no longer apply.

DKIM may survive forwarding if the message stays unmodified, but changes to the body or signed headers can break the signature. If neither SPF nor DKIM supplies an aligned pass at the final receiving server, DMARC may fail.

Some mail systems use ARC (Authenticated Received Chain) to pass along earlier authentication information. ARC helps a receiving provider consider a forwarding path; seeing an ARC entry alone does not prove the message is trustworthy.

The provider-specific treatment matters. Microsoft explains forwarding, alignment and ARC scenarios. There is no safe universal recipe for changing DNS based on an isolated forwarding failure.

A practical order for investigating a failure

  1. Identify which server wrote the result. Look for the receiving provider's trusted Authentication-Results field. Multiple providers along the route can add their own fields; the newest pasted line is not necessarily the one to trust.
  2. Record the actual From domain. That is the identity your recipient sees and the domain against which DMARC alignment is assessed.
  3. Check the SPF result and smtp.mailfrom domain. A pass means that SPF authentication succeeded for that envelope identity; compare it with From.
  4. Check the DKIM result and signing domain. If a passing DKIM domain aligns with From, DMARC can pass even when SPF does not.
  5. Find out whether a mailing platform or forwarder is involved. The setup may need custom domain authentication; forwarding may involve ARC and receiving-provider behaviour.
  6. Confirm the real DNS configuration and provider setup before editing anything. If you administer the sending domain, follow the provider's documented custom-domain instructions and retest with a message you send to a mailbox you control.

For a business sending transactional or marketing email, I would also test each sending service separately. A main inbox can work perfectly while a form provider, mailing platform or billing system still sends with the wrong signing identity.

Mistakes worth avoiding

“SPF says pass, so the email is legitimate.” No. SPF verifies a sending IP relationship for a domain; it does not establish that the content is safe, that the From domain aligns or that the sender is someone you should trust.

“I'll copy an SPF record from an online answer.” Blindly adding services may authorise infrastructure you do not use and still leave DMARC alignment wrong. A pass for an unrelated envelope domain cannot be fixed by guesswork.

“DKIM passes, so DMARC must pass.” A passing signature for another company's domain can be valid and still not align with the visible From.

“One failed forwarded message means my domain is broken.” Not necessarily. Look at the route, the trusted receiver's results and how original authentication was preserved.

“The pasted headers prove the email is authentic.” They don't. The Authentication-Results standard, RFC 8601, defines how these results are recorded, but their trust depends on who added them and where you obtained them.

What a successful retest looks like

Send a fresh message through the specific service you're trying to fix, to a mailbox you control. Inspect that receiver's trusted result.

You want DMARC to pass because either SPF passed with an aligned envelope domain, DKIM passed with an aligned signing domain, or both. Recheck after any provider or DNS change. A header view is the start of the investigation, not the final security verdict.

If you have a real header in front of you, open the Email Header Analyzer to lay out the claims and hops. Then check the sending provider's account settings and the receiving provider's authentication evidence before making a configuration change.

Sources & references
  1. email authentication troubleshooting guide
  2. the domain-alignment troubleshooting process
  3. Authentication-Results standard, RFC 8601