The Structure of a Response
Similar to requests, HTTP responses returned by servers contain three blocks: a status line, headers containing metadata, and the response body (HTML, JSON, images).
HTTP Snippet
http
HTTP/1.1 200 OK
Date: Fri, 14 Aug 2026 12:00:00 GMT
Content-Type: text/html
Content-Length: 38
<html><body>Hello World</body></html>The Status Line
The status line indicates the server protocol version and the numerical status code, along with a short text description (e.g. "200 OK" or "404 Not Found").
Response Headers
Headers pass information about the server software, content constraints, and caching directives (such as "Cache-Control" or "Set-Cookie").
