Skip to content
RU
← All HTTP Headers
Security

X-XSS-Protection

Legacy header that enabled the browser's built-in XSS filter. Now deprecated in favor of Content-Security-Policy.

Syntax

X-XSS-Protection: 0 | 1 | 1; mode=block

Example

X-XSS-Protection: 0

Description

X-XSS-Protection enabled the XSS filter in older browsers. Values: 0 (disable), 1 (enable), 1; mode=block (block page on detection).

Recommended modern value is 0 — the filter itself can introduce vulnerabilities.

Deprecated. Modern browsers removed the XSS auditor. Use Content-Security-Policy instead.

How real sites send this header

Home-page responses of 503 popular sites from the enterno.io /check catalogue, checked in the last 30 days.

29.2% (147 of 503) send X-XSS-Protection.

Most common values:

  • 1; mode=block — 107 sites
  • 0 — 26 sites
  • 1 — 9 sites

See it on: google.com, yandex.ru, discord.com, github.com, cloudflare.com

Check if your website sends this header correctly

Check your headers →

Related Articles

Related Headers

Related guides

Longer-form reading on this topic from the knowledge base.

Automate this check

Set up continuous monitoring and get an alert when something breaks. No manual runs to remember.