Example
How to read it
- multipart/alternative means the same message in plain text and HTML.
- multipart/mixed usually means there are attachments.
- The charset parameter tells apps how to decode the text.
Can you trust it?
Technical; set by the sender. To check an email you are unsure about, paste its full headers into the email header analyzer, or receive it in a temporary inbox where the Email X-ray checks it for you.
How to view email headers
- Gmail: open the message, click the three dots, then Show original.
- Outlook: open the message, then File, Properties, Internet headers (desktop), or the three dots, View, View message details (web).
- Apple Mail: View, Message, All Headers.
- Yahoo Mail: the three dots, then View raw message.
Where Content-Type sits in a real message
Every email has a header block at the top, then a blank line, then the body. Your mail app hides most of the header block and shows only a few fields. Here is a short, realistic header block with the Content-Type line highlighted:
Received: from mail.example.com (mail.example.com [192.0.2.10]) by mx.yourprovider.com
Authentication-Results: mx.yourprovider.com; spf=pass; dkim=pass; dmarc=pass
From: "Example Store" <news@example.com>
Content-Type: multipart/alternative; boundary="b1"
Subject: Your order has shipped
Date: Thu, 12 Nov 2026 09:14:03 -0500
Servers add their lines at the top as the message travels, so the newest information is first and the sender's original fields are lower down. When you read a header block, start at the top with the lines your own provider added, then work down.
About format headers
Format headers describe how the body is built: plain text, HTML, attachments and the character set. They matter most when a message looks broken, and they can reveal hidden parts such as an attachment disguised with a misleading name.
Checking Content-Type on a suspicious email
- Treat it as a helpful hint, not as proof. It is usually set by software along the way and is rarely checked.
- Use it together with Received and Authentication-Results to build a picture of where the message came from.
- Values that do not fit the claimed sender, such as a cheap bulk-mail tool on a message from a large bank, are worth a closer look.
Notes for developers
- Header names are case-insensitive, so
Content-Type,content-typeandCONTENT-TYPEare the same field. - Long values can be folded across several lines. A line that starts with a space or tab continues the previous header (RFC 5322 section 2.2.3).
- Non-ASCII text in header values is sent as encoded words such as
=?UTF-8?B?...?=(RFC 2047). Decode them before you display or compare values. - Some fields may appear more than once. Received, for example, appears once per hop. Decide whether your code needs the first, the last or all of them.
- Never use this header to make a security decision unless your own server added or verified it.
Other format headers
| Header | What it does |
|---|---|
| MIME-Version | Declares that the message uses MIME formatting, which allows attachments, HTML and non-English text. |
| Content-Transfer-Encoding | Says how a part was encoded for safe transport: 7bit, 8bit, quoted-printable or base64. |
| Content-Disposition | Says whether a part should be shown inline or offered as an attachment, and gives its filename. |
A scenario: the attachment that is not what it says
A message shows an attachment called "invoice.pdf", but the Content-Type for that part is application/x-msdownload and the full filename is "invoice.pdf.exe". Format headers reveal what a part really is, which is why mail filters and the Email X-ray look at them instead of trusting the visible name.
Quick checklist
- Check Content-Type for each attachment.
- Be wary of double extensions such as .pdf.exe.
- Confirm charset when text looks garbled.
Content-Type in raw, parsed and displayed form
| View | What you see |
|---|---|
| Raw source | Content-Type: multipart/alternative; boundary="b1" |
| Parsed by a mail library | A field named content-type with its decoded value |
| Shown by most mail apps | Hidden unless you open the full source |
Related guides
Related headers
- Content-Transfer-Encoding: Says how a part was encoded for safe transport: 7bit, 8bit, quoted-printable or base64.
- Content-Disposition: Says whether a part should be shown inline or offered as an attachment, and gives its filename.
- MIME-Version: Declares that the message uses MIME formatting, which allows attachments, HTML and non-English text.
FAQ
What is the Content-Type header?
Says what kind of content the message or part contains, such as text/plain, text/html or multipart/mixed, plus the character set.
Who sets the Content-Type header?
The sender's mail app.
Can the Content-Type header be faked?
Technical; set by the sender.
Is the Content-Type header required?
No. Content-Type is optional. Many messages do not include it, and its absence is not a problem on its own.
Why is Content-Type missing from my email?
Mail apps hide most headers. Open the full source (Show original in Gmail, View message details in Outlook) to see every header. If Content-Type is still not there, the sending software simply did not add it.
What is a multipart message?
A message with several parts, such as plain text, HTML and attachments, separated by boundaries.
Why does an email show as plain text only?
The HTML part is missing or your app is set to prefer plain text.