Lukas' Notes

web

Definition

HTTP Response Header

An HTTP response header is an HTTP header sent by the server to describe the reply. They appear after the status line (HTTP/version [[Knowledge/HTTP Status Code|code]] reason) and before the blank line that ends the header section.

Common examples:

  • Content-Type — the media type of the response body (e.g. text/html; charset=utf-8).
  • Content-Length — the byte length of the response body.
  • Location — the target URL for a redirect (3XX).
  • Set-Cookie — the cookie the server attaches to the client for future requests.
  • Date — the server’s timestamp for the response.
  • Connection — connection control, e.g. close.
  • X-Powered-By — a non-standard banner advertising the server framework; servers should withhold it to reduce information disclosure.