What are headers and why are they important?

Still have a question, spotted an error, or have a better explanation or a source we should cite?

Email headers are the hidden metadata attached to every email you send or receive. They record every technical detail of the message's journey: who sent it, who received it, which servers it passed through, when, and whether authentication checks passed or failed.

Headers live behind the scenes. When you open an email in Gmail, Outlook, or any other client, you're seeing the message body (the content). The headers are tucked away in a "Show Original" or "View Source" option. They're written for machines, not humans, but they tell you everything that actually happened to the email.

Here's what headers contain:

  • From/To/Subject: The basic addressing info you see in your inbox view
  • Received lines: A reverse-chronological log of every mail server the message passed through, with timestamps. The more hops, the more Received lines.
  • Authentication results: Whether SPF, DKIM, and DMARC passed or failed
  • Message-ID: A unique identifier for this exact message
  • Return-Path: Where bounces should go
  • Content-Type: Whether it's plain text, HTML, multipart, etc.
  • X-headers: Custom fields added by servers along the way (spam scores, internal routing tags, anything proprietary)

Why headers matter: they're your diagnostic tool when email breaks. If a message lands in spam, the headers show you which authentication check failed. If delivery is slow, the Received lines show you where the delay happened. If you're accused of sending email you didn't send, the headers prove whether it actually came from your server or was spoofed.

Headers are also how mailbox providers decide what to do with your email. When Gmail receives a message, it reads the headers first. It checks the authentication results, looks at the sending IP's reputation, scans for known spam patterns in the routing path. The message body comes second. Headers are the first line of defense (and the first place things go wrong).

If you've never looked at headers before, try this: open any email in your inbox, find "Show Original" (Gmail) or "View Message Source" (Outlook), and scroll through. You'll see lines like Received: from mail-server.example.com and Authentication-Results: spf=pass. It looks like gibberish at first, but once you know what you're looking at, it's incredibly useful. Reading Received headers is its own skill, worth learning if you troubleshoot delivery issues.

Quick example: You send a marketing email from your ESP. Your subscriber replies saying it never arrived. You check your ESP logs and it says "delivered." But when you ask them to forward the bounce message, you see in the headers: spf=fail. That's the problem. Your SPF record is broken, and their mailbox rejected it. Without headers, you're guessing. With headers, you know exactly what failed.

So you can also check headers with our free Email Header Analyzer if you want a human-readable breakdown instead of raw text. Or if you're stuck on a delivery issue and headers aren't making sense, our SOS hotline is always free (we actually pick up).

Contributors

Who worked on this answer

Every name links to their profile. Every company links to their site. Real people, real accountability.

Ask an AI · tailored to your setup

Get personalized help with your headers →

I read this on the Email Almanac about email headers: they're the hidden metadata that records routing, authentication, and technical details for every message. Help me apply this to MY situation: 1. My email platform/ESP: e.g. Mailchimp, SendGrid, Gmail, custom SMTP 2. My current challenge: [e.g. emails landing in spam, slow delivery, accused of spoofing, debugging a bounce] 3. What I've tried so far: if anything 4. My experience level: beginner / intermediate / advanced Based on what I shared, help me: - Understand which header fields matter most for my issue - Know where to find headers in my email client or ESP dashboard - Spot the red flags in headers that indicate my specific problem - Get a step-by-step plan to fix what's broken

Edit the yellow boxes, then send to the AI of your choice.