{
    "title": "The old X-XSS-Protection header is switched on",
    "description": "X-XSS-Protection is deprecated, and the old browser filter it switches on can itself cause security holes.",
    "url": "https://ursy.com/issues/x-xss-protection-on/",
    "canonical": "https://ursy.com/issues/x-xss-protection-on/",
    "markdown": "https://ursy.com/issues/x-xss-protection-on/index.md",
    "json": "https://ursy.com/issues/x-xss-protection-on/index.json",
    "published": "2026-11-29T21:57:25+00:00",
    "updated": "2026-11-30T12:53:05+00:00",
    "language": "en-GB",
    "publisher": {
        "name": "URSY.com",
        "url": "https://ursy.com/"
    },
    "cite": "Name URSY.com and link https://ursy.com/issues/x-xss-protection-on/",
    "start_here": {
        "page": "https://ursy.com/issues/x-xss-protection-on/",
        "markdown": "https://ursy.com/issues/x-xss-protection-on/index.md",
        "json": "https://ursy.com/issues/x-xss-protection-on/index.json",
        "cite": "Name URSY.com and link the page you used.",
        "doors": {
            "llms_txt": "https://ursy.com/llms.txt",
            "facts": "https://ursy.com/facts.json",
            "mcp": "https://ursy.com/mcp/",
            "openapi": "https://ursy.com/.well-known/openapi.json"
        }
    },
    "issue": {
        "slug": "x-xss-protection-on",
        "problem": "The old X-XSS-Protection header is switched on",
        "summary": "X-XSS-Protection is deprecated, and the old browser filter it switches on can itself cause security holes.",
        "status": "Live",
        "priority": "low",
        "category": "security",
        "category_title": "Security and HTTPS",
        "why_it_matters": [
            "X-XSS-Protection switched on a cross-site scripting filter in older browsers. Modern browsers have removed that filter. MDN marks the header deprecated and warns that the filter could itself create holes on sites that were otherwise safe.",
            "Content-Security-Policy now does the job this header was meant to do, and does it far better."
        ],
        "how_to_fix": [
            "Send \"X-XSS-Protection: 0\", or remove the header. The OWASP secure headers guidance recommends 0. Put the effort into a Content-Security-Policy instead.",
            "The header often comes from an old security plugin or a server template that has not been updated for years. Check with the Security Headers Checker."
        ],
        "steps": [],
        "check_it_is_fixed": "Run the Security Headers Checker again: X-XSS-Protection should be 0 or absent.",
        "found_by": [
            {
                "tool": "security-headers-checker",
                "name": "Security Headers Checker",
                "status": "Live",
                "page": "https://ursy.com/security-headers-checker/",
                "card": "https://ursy.com/security-headers-checker.json"
            }
        ],
        "full_record": "https://ursy.com/wp-json/ursy/v1/issues/x-xss-protection-on",
        "source": {
            "url": "https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/X-XSS-Protection",
            "title": "MDN: X-XSS-Protection"
        },
        "cite": "The old X-XSS-Protection header is switched on. URSY.com. https://ursy.com/issues/x-xss-protection-on/"
    },
    "headings": [
        {
            "level": 2,
            "text": "Why it matters",
            "id": "why-it-matters",
            "url": "https://ursy.com/issues/x-xss-protection-on/#why-it-matters"
        },
        {
            "level": 2,
            "text": "How to fix it",
            "id": "how-to-fix-it",
            "url": "https://ursy.com/issues/x-xss-protection-on/#how-to-fix-it"
        },
        {
            "level": 3,
            "text": "What the problem looks like",
            "id": "what-the-problem-looks-like",
            "url": "https://ursy.com/issues/x-xss-protection-on/#what-the-problem-looks-like"
        },
        {
            "level": 3,
            "text": "What it looks like fixed",
            "id": "what-it-looks-like-fixed",
            "url": "https://ursy.com/issues/x-xss-protection-on/#what-it-looks-like-fixed"
        },
        {
            "level": 2,
            "text": "Fix it with your AI assistant",
            "id": "fix-it-with-your-ai-assistant",
            "url": "https://ursy.com/issues/x-xss-protection-on/#fix-it-with-your-ai-assistant"
        },
        {
            "level": 2,
            "text": "Fix it on your platform",
            "id": "fix-it-on-your-platform",
            "url": "https://ursy.com/issues/x-xss-protection-on/#fix-it-on-your-platform"
        },
        {
            "level": 3,
            "text": "WordPress",
            "id": "wordpress",
            "url": "https://ursy.com/issues/x-xss-protection-on/#wordpress"
        },
        {
            "level": 3,
            "text": "Your server or hosting",
            "id": "your-server-or-hosting",
            "url": "https://ursy.com/issues/x-xss-protection-on/#your-server-or-hosting"
        },
        {
            "level": 3,
            "text": "Your CDN (for example Cloudflare)",
            "id": "your-cdn-for-example-cloudflare",
            "url": "https://ursy.com/issues/x-xss-protection-on/#your-cdn-for-example-cloudflare"
        },
        {
            "level": 2,
            "text": "Check it is fixed",
            "id": "check-it-is-fixed",
            "url": "https://ursy.com/issues/x-xss-protection-on/#check-it-is-fixed"
        },
        {
            "level": 2,
            "text": "Official source",
            "id": "official-source",
            "url": "https://ursy.com/issues/x-xss-protection-on/#official-source"
        },
        {
            "level": 2,
            "text": "Questions",
            "id": "questions",
            "url": "https://ursy.com/issues/x-xss-protection-on/#questions"
        },
        {
            "level": 3,
            "text": "Is turning a protection off unsafe?",
            "id": "is-turning-a-protection-off-unsafe",
            "url": "https://ursy.com/issues/x-xss-protection-on/#is-turning-a-protection-off-unsafe"
        },
        {
            "level": 3,
            "text": "Should I set it to 0 or remove it?",
            "id": "should-i-set-it-to-0-or-remove-it",
            "url": "https://ursy.com/issues/x-xss-protection-on/#should-i-set-it-to-0-or-remove-it"
        }
    ],
    "links": [
        {
            "text": "ChatGPT",
            "url": "https://ursy.com/wiki/chatgpt/",
            "internal": true
        },
        {
            "text": "CDN",
            "url": "https://ursy.com/wiki/cdn/",
            "internal": true
        },
        {
            "text": "MDN: X-XSS-Protection",
            "url": "https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/X-XSS-Protection",
            "internal": false
        }
    ],
    "words": 481,
    "text": "X-XSS-Protection is deprecated, and the old browser filter it switches on can itself cause security holes. Why it matters X-XSS-Protection switched on a cross-site scripting filter in older browsers. Modern browsers have removed that filter. MDN marks the header deprecated and warns that the filter could itself create holes on sites that were otherwise safe. Content-Security-Policy now does the job this header was meant to do, and does it far better. How to fix it Send \"X-XSS-Protection: 0\", or remove the header. The OWASP secure headers guidance recommends 0. Put the effort into a Content-Security-Policy instead. The header often comes from an old security plugin or a server template that has not been updated for years. Check with the Security Headers Checker. What the problem looks like X-XSS-Protection: 1; mode=block Switches on an old browser filter that modern browsers have removed and that could itself be misused. What it looks like fixed X-XSS-Protection: 0 Or leave the header out. Protect the site with a Content-Security-Policy instead. Fix it with your AI assistant Paste this into ChatGPT, Claude, Gemini or your coding agent, and fill in the words in square brackets: Help me update an old security header on [your website address], which runs on [your platform or server, e.g. WordPress on Apache]. A checker says X-XSS-Protection is switched on. Modern browsers have removed the filter it controls, and in older browsers that filter could create holes on pages that were otherwise safe. First check: run \"curl -sI https://[your domain]/\" (or ask me to paste the headers) and find every place that could add this header: server configuration, .htaccess, a security plugin, the theme, the CDN or the application code. Explain plainly where it comes from. Then give me the exact change: set \"X-XSS-Protection: 0\" or remove the header, at its source, once. Rules: back up first, change only this header, keep every other security header, and do not remove a Content-Security-Policy. Give the exact line to change and where it lives. Finally, tell me to re-check with the URSY.com Security Headers Checker at ursy.com/security-headers-checker/. Fix it on your platform WordPress Old security plugins often add this header. Look for an X-XSS-Protection option and set it to 0 or off. Your server or hosting Search the server configuration and .htaccess for X-XSS-Protection and change the value to 0, or remove the line. Your CDN (for example Cloudflare) If the CDN adds security headers for you, check whether it adds this one and change it there. Check it is fixed Run the Security Headers Checker again: X-XSS-Protection should be 0 or absent. Official source MDN: X-XSS-Protection Questions Is turning a protection off unsafe? No. Current browsers ignore it, and 0 stops older browsers using a filter that could be abused. A Content-Security-Policy is the real protection. Should I set it to 0 or remove it? Either is fine. Security header guidance recommends 0, which makes the choice clear.",
    "source": "https://ursy.com/issues/x-xss-protection-on/"
}