What email headers tell you and why they matter

Email headers are the routing information hidden behind every message you receive. They show the path your email took from sender to your inbox, the servers it passed through, and timestamps at each step. Most email programs hide headers by default because they're technical and long, but they're the only reliable way to see where a message actually originated.

Headers matter because email addresses can be spoofed — someone can send a message that appears to come from your bank or a friend, but actually came from somewhere else entirely. The IP address in the headers is much harder to fake. It's the numerical address of the computer that sent or relayed the message, and it's recorded by every server the email passes through.

Reading headers won't turn you into a forensic investigator, but it will show you whether a suspicious message is what it claims to be. If an email says it's from your mortgage lender but the originating IP belongs to a data center in Eastern Europe, that's a red flag worth taking seriously.

Key Takeaways

  • Email headers are hidden by default in most programs, but you can unhide them in Gmail, Outlook, Apple Mail, and most other services with a few clicks.
  • The Return-Path or From header shows the sender's address, but this can be spoofed; the Received headers show the actual servers involved and are much harder to fake.
  • The originating IP address appears in the topmost Received header (the one closest to the sender) and is the most useful piece of information for determining where a message really came from.
  • IP addresses can be looked up in free databases to see what organization owns them and what geographic region they're in, which helps you spot phishing and spam.
  • Even with headers visible, you cannot definitively prove who sent an email — only which server it came from — so use this information alongside other context clues.

How to view headers in Gmail

Open the message you want to check. Click the three vertical dots (the menu icon) in the top right corner of the email. Select Show original from the dropdown menu. A new window opens showing the complete raw email, including all headers at the top.

The headers are dense and hard to read at first. Scroll to the very top and look for the section labeled Received: — there will be multiple Received lines stacked on top of each other. The topmost one (the last one you see when you scroll to the very top) is the one closest to the original sender. That line will include an IP address in square brackets, like [192.0.2.1]. That's the originating IP you're looking for.

Gmail also shows you the Return-Path header near the top, which displays the sender's email address. Remember that this can be spoofed, so don't rely on it alone. Cross-reference it with the IP address to get a fuller picture.

How to view headers in Outlook and Outlook.com

In Outlook on the desktop, open the message and go to the File menu. Click Properties (or Info depending on your version). A dialog box opens; look for the Internet Headers section and click inside it to see the full header text.

In Outlook.com (the web version), open the message and click the three dots menu in the top right. Select View message details or View message source. The headers appear in a panel on the right side of the screen. Again, scroll to the very top to find the originating IP address in the topmost Received header.

How to view headers in Apple Mail and other programs

In Apple Mail on Mac, open the message. Go to the View menu and select Message > All Headers. The headers appear at the top of the message window. On iPhone or iPad, open the message, tap the sender's name at the top, then scroll down and tap Details to see header information (though the mobile version shows less detail than the desktop version).

In most other email programs — Yahoo Mail, ProtonMail, Thunderbird, and others — look for a menu option labeled Show Headers, View Source, View Raw, or Message Details. The exact wording varies, but the concept is the same. If you can't find it, search the program's help documentation for "view headers" or "view source".

How to find and interpret the originating IP address

Once you have the headers open, find the topmost Received: line — the one that appears first when you scroll to the very top of the header block. This line will look something like this:

Received: from mail.example.com (mail.example.com [203.0.113.45]) by smtp.gmail.com with SMTP id abc123def456

The IP address is the number in square brackets: [203.0.113.45]. Copy that number (without the brackets). This is the IP address of the server that sent the email or the last server to handle it before it reached your inbox.

Paste the IP address into a free lookup tool like IP2Location, MaxMind GeoIP2, or AbuseIPDB. These tools will tell you what organization owns that IP address, what country and city it's registered to, and whether it's been reported for spam or abuse. If the email claims to be from your bank but the IP belongs to a residential internet provider in a different country, that's a strong sign the message is fraudulent.

What the other headers tell you

The From: header shows the sender's email address as displayed in your inbox. This is straightforward to spoof, so don't trust it on its own. The Return-Path header shows where bounce-back messages go if delivery fails; this is also spoofable but slightly harder to fake than the From field.

The Subject: header is just the subject line. The Date: header shows when the email was sent, according to the sender's server — but this can be manually set to any date, so it's not reliable for determining when something actually happened.

The Message-ID: header is a unique identifier assigned by the sending server. It's useful for tracking a specific message through multiple servers, but it doesn't tell you who the sender is.

What headers cannot tell you

Headers show you the servers involved in delivering an email, but they don't prove who actually typed the message. A compromised email account, a spoofed server, or a relay service can all make it look like a message came from somewhere it didn't. An IP address tells you which organization owns the server, but not which person used it.

If you're investigating a serious matter — fraud, harassment, or a crime — headers are a starting point, not proof. Law enforcement and email providers have tools to dig deeper than what headers show. If you need to report something, contact the organization that owns the IP address (using the abuse contact listed in the lookup results) or file a report with your local police or the FBI's Internet Crime Complaint Center.

Frequently Asked Questions

Can someone hide their IP address in email headers?

Not completely. The originating IP is recorded by the first server to handle the email, and that server is usually outside the sender's control. However, someone could send through a VPN, a proxy, or an anonymizing service, which would show that service's IP instead of their own. That still narrows things down and can be reported to the service provider.

What if the IP address is from Gmail or Outlook?

If the originating IP belongs to Google, Microsoft, or another major email provider, the email was sent through their servers. This is normal for legitimate messages from those services, but it also means a compromised account could send a spoofed message through the same servers. Look at the other headers — the Authentication-Results header may show whether the message passed SPF, DKIM, or DMARC checks, which are harder to fake.

Is it illegal to trace an email?

Reading your own email headers is not illegal. Looking up an IP address in a public database is not illegal. Attempting to hack into someone's email account or using someone else's email to send messages is illegal. If you suspect a crime, report it to law enforcement rather than trying to investigate on your own.

Can I trace an email if I deleted it?

If you permanently deleted the email, you cannot retrieve the headers from your own account. However, if the email was sent to multiple people, one of those recipients might still have it. If it's a serious matter, contact your email provider's support team — they may be able to recover deleted messages or provide server logs showing where the message came from.

What does SPF, DKIM, or DMARC mean in the headers?

These are authentication standards that make it harder to spoof email. SPF checks whether the sending server is authorized to send mail for that domain. DKIM adds a digital signature to the message. DMARC ties them together and tells receiving servers what to do if the checks fail. If a message fails these checks, it's more likely to be fraudulent, though legitimate mail sometimes fails them too.