To see the HTTP response headers of a page, open your browser’s DevTools (F12) → Network, reload, click the first request and read Response Headers. On the command line, curl -I https://example.com prints them. Our HTTP Headers checker fetches both the http and https version of a site and shows every redirect step with its headers, which is handy for checking redirects, caching and security headers from outside your own network.
In the browser
- Press F12 (or Cmd+Option+I on macOS) and open the Network tab.
- Reload the page. Tick Disable cache to see what the server sends, not the cached copy.
- Click the first row (the document) and open Headers. Response Headers are what the server sent; Request Headers are what your browser sent.
Tick Preserve log to keep earlier requests when the page redirects, so you can see each step of a redirect chain.
With curl
curl -I https://example.com
curl -sD - -o /dev/null https://example.com
curl -sIL http://example.com
-I sends a HEAD request; a few servers answer HEAD differently from GET, so the second form makes a real GET and prints only the headers. -L follows redirects and prints the headers of every step.
With PowerShell
(Invoke-WebRequest https://example.com -Method Head -UseBasicParsing).Headers
curl.exe -I https://example.com
On Windows 10 and 11, curl.exe is built in; type curl.exe rather than curl, which in Windows PowerShell 5.1 is an alias for Invoke-WebRequest.
Which headers to look at
| Header | Why it matters |
|---|---|
Location with 301/302/307/308 | Where a redirect points; see 301 vs 302 redirects |
Cache-Control, ETag, Age | How long browsers and CDNs may cache the page |
Strict-Transport-Security | Forces HTTPS on future visits (HSTS) |
Content-Security-Policy | Limits where scripts and other resources can load from |
X-Content-Type-Options, Referrer-Policy | Basic hardening headers |
Server, X-Powered-By | Reveal software versions; better hidden |
CF-Cache-Status, X-Cache | Whether a CDN served the page from its cache |
A complete list of recommended security headers is in the HTTP security headers checklist.
Common Questions
Why do I see different headers in the browser and in curl?
The browser sends cookies, a different User-Agent and Accept headers, and may use HTTP/2 or HTTP/3. Servers and CDNs can answer differently based on these, and the browser may also show a cached response.
Can I see the headers of a site that redirects?
Yes. Use curl -sIL or our HTTP Headers checker, which list each redirect step with its status code and Location header.
Why does curl -I return 405 or 404 when the page works?
Some applications do not support HEAD requests. Use curl -sD - -o /dev/null URL to make a normal GET request and print only the headers.
Are response headers visible to everyone?
Yes. Anyone who requests the page receives them, so never put secrets or internal details in headers.