Security Headers Checker

Grade any site's HTTP response security headers, with a concrete fix for every miss.

Our server fetches the URL once and reads its response headers. Nothing is stored. Only check sites you're authorized to assess.

How it works

The checker sends a GET request to the supplied public URL and follows redirects. It grades seven checks against the final response. Review the displayed URL and status first. A redirect can land on another host, a login page or an error page with its own policy. A single result covers the response the checker received, while other pages, assets and authenticated routes may return different headers.

What each security header does

CheckPurpose and starting value
Strict-Transport-Security (HSTS)After a valid HTTPS response, browsers remember to use HTTPS for this host. Once HTTPS is working, pilot max-age=300 on the HTTPS response. Extend the lifetime gradually and add includeSubDomains only after confirming HTTPS across subdomains.
Content-Security-Policy (CSP)Limits the sources and actions a browser permits, reducing the impact of script injection. Trial default-src 'self'; object-src 'none'; base-uri 'self' in the report-only header before enforcing. Review dependencies on inline scripts, external assets and sign-in flows first.
X-Content-Type-OptionsUse nosniff to tell browsers to respect the declared content type. Incorrectly typed scripts or styles can be blocked, so verify the actual Content-Type for those assets.
X-Frame-Options or CSP frame-ancestorsRestricts which pages can embed this response and helps prevent clickjacking. If framing is unnecessary, start with frame-ancestors 'none' in enforced CSP and DENY in X-Frame-Options for older clients. Test legitimate embeds before rollout.
Referrer-Policystrict-origin-when-cross-origin sends only the origin to another HTTPS origin, preserves the referrer URL on same-origin requests subject to normal stripping, and omits it on HTTPS-to-HTTP requests. Use a tighter policy where referring URLs are especially sensitive.
Permissions-PolicyControls access to supported browser features. Begin with camera=(), microphone=(), geolocation=() only if those features are unused. Check browser support and embedded content before enforcing restrictions.
ServerA banner can disclose server software and version details. Prefer an omitted or version-free banner. Start with server_tokens off on nginx or ServerTokens Prod in Apache's global configuration. Patching still matters.

Worked examples

Assume every check passes except CSP and HSTS. If you send only Content-Security-Policy-Report-Only, the CSP check receives zero of its 25 points. If HSTS is present with the short pilot lifetime above, that warning receives 10 of its 20 points. The hypothetical result is 65%, grade C. Use the short HSTS rollout and report-only CSP to validate behavior before seeking a higher grade.

Suppose the home page is green but an application path is missing multiple headers. Inspect that path and an error route on a test deployment. On nginx, a location that declares its own add_header directives replaces the inherited list by default. Apache can emit duplicate values from its different response header tables. An upstream application or CDN may also add a second policy. Check the delivered headers before adding another copy.

For CSP, check which directive the violation refers to before changing the allowlist. Adding 'unsafe-inline' just to fix an inline script weakens script restrictions. Prefer a nonce, a hash or a permitted external script when appropriate. Set frame-ancestors explicitly if you want CSP to govern framing.

What to do with your result

Each passing check earns full weight, a warning earns half and a failure earns zero. The checker assigns A from 90%, B from 75%, C from 55%, D from 35% and F below 35%, using the unrounded percentage. Read failed rows to see the observed values and guidance. Presence alone can pass some checks, so review header syntax and the effect in a browser. The OWASP Secure Headers Project documents what the policies control.

Choose which layer will own each header. For a starting configuration, select nginx or Apache in the Security Headers Generator and review the values before deploying. For example, in the nginx HTTPS server block:

add_header X-Content-Type-Options "nosniff" always;

With mod_headers enabled, the Apache virtual host equivalent is:

Header always set X-Content-Type-Options "nosniff"

The always option helps cover error responses. Validate the configuration, reload in staging and retest representative pages and a controlled error. Inspect the public response after the CDN or proxy, since that is what browsers receive. Compare a real GET in your browser's Network panel with the checker's result. Login sessions, redirects and cache state can account for different responses. Use the HSTS setup guide and CSP report-only rollout for staged deployment. If a header check leads to a confirmed vulnerability that needs a CVSS rating, see the CVSS 3.1 scoring walkthrough for how to document it.

FAQ

How do I check the security headers on my website?

Enter the public URL you want to test and run the check. Confirm the returned URL and status, then review the observed values. Repeat for representative routes you are authorized to test.

Does an A grade mean my site is secure?

The grade summarizes a set of checks on one HTTP response. Assess authorization, software patches and application behavior separately. Even a high grade can include warnings or gaps.

Why does my CSP fail when report-only is enabled?

The report-only header lets you observe violations without enforcing the policy. The checker looks for the enforced Content-Security-Policy response header.

Do I need X-Frame-Options if I have frame-ancestors?

Modern browsers can use the frame-ancestors directive in enforced CSP. X-Frame-Options provides a fallback for older clients. Keep both policies consistent if you send both.

Why does my HSTS check warn about max-age?

The tool warns when it reads a max-age below 15,768,000 seconds, about six months. A shorter lifetime can be intentional during rollout. Increase it once you have verified reliable HTTPS.

Why do some pages show different headers on the same domain?

Different locations, applications, caches or error handlers can return different policies. Compare the exact response status and headers for each route before changing the server configuration.

From the channel

Video thumbnail: Information Disclosure Vulnerabilities Explained — Web Application Security for Beginners Information Disclosure Vulnerabilities Explained — Web Application Security for Beginners Watch safe, hands-on security demonstrations for complete beginners on The Exploit HQ ▸ Video thumbnail: The 10 curl Commands Every Security Tester Uses in 2026 The 10 curl Commands Every Security Tester Uses in 2026 Watch safe, hands-on security demonstrations for complete beginners on The Exploit HQ ▸