๐Ÿท๏ธ
๐Ÿงผ

Sanitise User Input for HTML Output

Encode user-provided strings before inserting them into HTML โ€” prevents XSS injection attacks.

No login required
Output:
Examples:
Plain text / HTML
Encoded HTML
Output will appear hereโ€ฆ
Common HTML entities reference
&&
<&lt;
>&gt;
"&quot;
'&#39;
ยท&nbsp;
ยฉ&copy;
ยฎ&reg;
โ„ข&trade;
โ‚ฌ&euro;
โ€”&mdash;
โ€ฆ&hellip;

Security tips

๐Ÿงผ

Paste any user input here to see exactly which characters get encoded. < becomes &lt;, > becomes &gt;, & becomes &amp; โ€” all rendered as text, not HTML.

๐Ÿ›ก๏ธ

Cross-Site Scripting (XSS) attacks inject <script> tags via user input fields. Encoding all user output is the primary defense.

๐Ÿ’ก

Always encode on output (when rendering), not on input (when saving). Store raw data, encode when displaying โ€” this avoids double-encoding bugs.

๐Ÿ”

Test with payloads like <script>alert(1)</script> and onmouseover="alert(1)" to verify your encoding catches all attack vectors.

How It Works

1
Enter
Enter your data into the tool above. Everything stays local to your browser.
2
Process
The tool processes your data instantly in your browser using JavaScript. No server, no waiting.
3
Download
Get your result instantly. Nothing is stored after you leave the page โ€” complete privacy.

Why use ours?

โœ“Completely free โ€” no hidden costs, ever
โœ“No account, email, or login required
โœ“Files never leave your device
โœ“No file size limits whatsoever
โœ“No watermarks on any output

Also check outโ€ฆ

Frequently Asked Questions