---
title: "How to Enable XSS Protection in WordPress?"
url: https://qa.nexterwp.com/docs/enable-xss-protection-in-wordpress/
date: 2023-09-29
modified: 2026-04-14
author: "Aditya Sharma"
description: "On a WordPress website, XSS is a common type of attack where malicious code is injected into a website, allowing an attacker to steal sensitive information from users or even..."
image: https://qa.nexterwp.com/wp-content/uploads/2024/05/enable-xss-protection-in-wordpress-1024x519.jpg
word_count: 153
---

# How to Enable XSS Protection in WordPress?

## Key Takeaways

- Enabling XSS protection on a WordPress website prevents malicious code injection and enhances security.
- Nexter Extension (Free) allows users to enable XSS protection through the WordPress Dashboard under Nexter > Extensions > Security.
- Activating the XSS Protection toggle in the Advanced Security section of the Nexter Extension automatically secures the site from cross-site scripting attacks.

On a WordPress website, XSS is a common type of attack where malicious code is injected into a website, allowing an attacker to steal sensitive information from users or even take control of the website. By enabling XSS protection, you can prevent these types of attacks and keep your website secure.

If you are using the [Nexter Extension (Free) plugin](https://wordpress.org/plugins/nexter-extension/), you can easily enable the XSS protection on your WordPress website.  

[LIVE EXTENSION LINK](https://qa.nexterwp.com/nexter-extensions/advanced-wordpress-security/)

 

## How to Enable XSS Protection with the Nexter Extension?

To enable the XSS protection with the Nexter Extension, from the WordPress Dashboard, go to **Nexter **>** Extensions**> **Security**.

Then go to the **Advanced Security **section, enable the toggle, and click on the gear icon (⚙).

![](https://qa.nexterwp.com/wp-content/uploads/2025/08/advanced-security-settings-new-1.png)

It will open the Advanced Security popup, then enable the **XSS Protection** toggle and click the **Save** button. 

![xss protection](https://qa.nexterwp.com/wp-content/uploads/2023/09/xss-protection-new.png)

It will automatically take all the necessary steps to protect your site from cross-site scripting.