iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more
An HTTP response header is a field in an HTTP response’s header section, sent before any response content. It supplies information that helps a client interpret or handle the response, such as its media type, caching rules, or the location of a resource. The status code is separate: it reports the outcome of the request.
What is an HTTP response header?
The standards term is header field; “header” is the common shorthand. RFC 9110 describes HTTP fields as extensible name-and-value pairs. A field can modify or extend message semantics, describe the sender, define content, or provide additional context. Fields can appear in request and response header sections, and in trailers when permitted. See RFC 9110, HTTP Semantics.
| # | Preview | Product | Price | |
|---|---|---|---|---|
| 1 |
|
High Performance Browser Networking: What every web developer should know about networking and web... | $30.87 | Buy on Amazon |
| 2 |
|
Learning HTTP/2: A Practical Guide for Beginners | $18.11 | Buy on Amazon |
| 3 |
|
HTTP: The Definitive Guide | $26.04 | Buy on Amazon |
| 4 |
|
HTTP Pocket Reference: Hypertext Transfer Protocol | $6.94 | Buy on Amazon |
| 5 |
|
HTTP/2 in Action | $42.73 | Buy on Amazon |
A response header is therefore metadata within the response, not the response content itself. The meaning of each field depends on its definition: some describe the representation, while others concern caching, the sender, or the resource.
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →How headers, status codes, and content differ
| Response part | Purpose | Example |
|---|---|---|
| Status code | Reports the outcome of the request as response control data. | 201 Created |
| Header section | Contains fields that add information about the response or how to handle it. | Content-Type: application/json |
| Content (body) | Carries the returned representation or other response content, when present. | {"message":"New user created"} |
The status code is not itself a header field. In the example above, the code reports that a resource was created, while the fields give additional information and the content carries a message. RFC 9110 distinguishes response control data, header fields, and content; field semantics are specified individually. See RFC 9110.
#1 Best Overall
- Used Book in Good Condition
Example: a response with headers
HTTP/1.1 201 Created
Content-Type: application/json
Location: https://example.com/users/123
Cache-Control: no-store
{"message":"New user created"}
This illustrative HTTP/1.1 response shows the status line first, followed by the header fields. A blank line separates the header section from the content. Content-Type describes the returned representation; Location can identify a related or newly created resource; and Cache-Control provides caching directives. The exact values and applicable rules depend on the response and each field’s definition. See RFC 9110.
Common response header fields
Content-Typedescribes the media type of the representation.Cache-Controlgives caching directives.DateandServerare examples of fields with defined meanings concerning the response or sender.Locationcan identify a related or newly created resource.
These names are examples, not interchangeable labels: each field has its own semantics and rules. For definitions and behavior, consult the relevant specification, including RFC 9110.
Rank #2
Field names, casing, and protocol versions
HTTP field names are case-insensitive, so different capitalization does not make a different field. Their displayed form can vary by protocol version and tooling. In HTTP/1.x, fields are conventionally shown as a name, a colon, and a value. In HTTP/2 and later, developer tools commonly display lowercase field names, and the protocol includes special colon-prefixed pseudo-headers. These are version-specific details; do not assume every HTTP version uses identical wire syntax. See MDN’s HTTP headers reference and RFC 9110.
Can a response have headers but no content?
Yes. A response to a HEAD request has no content, but generally includes the fields that a corresponding GET response would have, subject to the standard’s exceptions. This lets a client receive representation metadata without receiving the representation itself. See RFC 9110.
Rank #3
Should custom headers start with X-?
No. The X- prefix is not a requirement for custom HTTP fields; MDN notes that this convention was deprecated in 2012. For an interoperable field, use a properly defined and registered field name rather than relying on the prefix. See MDN’s HTTP headers reference.
Quick Recap
Best Value
Rank #4
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

