Skip to main content

Cloudflare _headers Tester

New

Test a Cloudflare Pages _headers file against any request path to see which headers are applied, with splat, placeholder and detach (!) support.

cloudflare pages _headers_headers testercustom headers cloudflarenetlify headers
Read the guide
Shortcuts:⌘ KSearch
Resulting headers

Rules apply top to bottom; all matching rules add headers, and repeated header names are joined with a comma. Use ! Header-Name to detach an inherited header. Applies to static assets only, not Pages Functions responses.

Continue with:

Frequently Asked Questions

How is _headers formatted?

A URL pattern on its own line followed by indented "Header-Name: value" lines. Blank lines separate rules.

What happens when several rules match?

All matching rules apply; repeated header names are joined with a comma.

How do I remove a header?

Use "! Header-Name" under a matching rule to detach a header added by an earlier rule.

Do _headers apply to Functions?

No, they apply only to static asset responses. Set headers in code for Functions responses.

Related Tools