Free tool

Decode an email's headers

Paste the raw headers of an email: we read the SPF, DKIM and DMARC results written by the server that received it, the path it took from server to server and the time spent at each step. The analysis runs in your browser: what you paste is never sent or stored.

Analysis runs in your browser: the pasted text is neither sent nor stored.

What this decoder reads

Before its body, an email carries a series of headers written by the servers that handled it. The decoder draws three things from them. First, the authentication result: the Authentication-Results header says whether SPF (was the sending server allowed to write for that domain), DKIM (is the message signature valid) and DMARC (is the domain shown in the From field the one that was authenticated) passed. Second, the path: each server crossed adds a Received header, and we put them back in sending order. Third, the delays: the difference between two successive dates shows where the message waited. Everything is read from the text you paste, without querying the domain or any outside service.

How to read the result

Look at the three results first. "pass" means the check succeeded; "fail", "softfail", "permerror" or "temperror" mean a failure; "none" or "neutral" mean the domain published nothing or takes no position. DMARC only passes if SPF or DKIM passes and the authenticated domain matches the one in the From field: an SPF "pass" can therefore come with a DMARC "fail". Trust the Authentication-Results header that sits highest in the list: it is the one your own receiving server added last. The ones below may have been written by any server along the way, or even by the sender. The path table reads from top to bottom, from the originating server to the receiving one; the slowest step is flagged. Badly set clocks can produce a negative delay: that is not a real delay.

The most common causes of an email going to spam

  • A sending service (newsletter, invoicing, web form) missing from the domain's SPF record: SPF fails or stays at "softfail".
  • No DKIM signature, or a signature made for the sending service rather than for your domain: DKIM is missing or does not match the From field.
  • SPF or DKIM passes but with a different domain than the one in the From field: DMARC fails for lack of a match.
  • A message modified on the way (footer added by a mailing list, forwarding): the DKIM signature is no longer valid.

What to do next

Depending on the result, go back to the point at fault. SPF failing: add the sending service to your domain's SPF record, without going over the DNS lookup limit. DKIM missing or not aligned: turn on signing at your sending provider, with your own domain. DMARC failing: check that one of the two previous checks passes with the From domain, then publish or tighten the policy. The three free tools on this site re-read your domain's record and offer the fix to copy. If the message was rejected with an error code, the error pages on the blog explain each case.

Frequently asked questions

Is what I paste sent anywhere?

No. The analysis is done by the page's code, in your browser. The text is not sent to our servers, not placed in the page address, not stored. It disappears when you close or reload the page.

How do I get an email's raw headers?

In your mail client, open the message and look for "Show original" (Gmail), "View message details" (Outlook) or "Show all headers" (most others). Copy the whole header block, up to the first blank line.

Why does the authentication not appear?

The server that received the message did not write an Authentication-Results header, or you did not copy the headers in full. The decoder then reads the Received-SPF header if there is one, and shows "absent" for the rest.

What does dkim=fail mean when SPF passes?

The two checks are independent. SPF checks that the sending server was authorised for the domain of the envelope address; DKIM checks the message signature. dkim=fail means the message was signed but the signature could not be verified: most often the message was changed in transit (footer added, mailing list, rewriting by a filter), or the key published in DNS has changed since signing. DMARC can still pass through SPF, provided its domain matches the one in the From field.

Why is one step of the path flagged as the slowest?

For each Received header, the decoder computes the gap with the previous readable date, then flags the step where that gap is largest. It is a comparison, not a threshold: the slowest step may have waited only a few seconds. A wait of several minutes usually comes from filtering, a queue or a new attempt after a temporary rejection; RFC 5321 recommends spacing those attempts at least 30 minutes apart. A negative delay comes from badly set clocks and is never flagged as slow.