HTML Entity Encoder / Decoder
Convert characters to HTML entities (escape HTML) to prevent rendering conflicts, or convert them back (unescape). Runs locally.
Input Text
Output Result
Frequently Asked Questions
Everything you need to know about processing files securely in your browser
What are HTML entities?
HTML entities are sequences of characters used to display reserved characters (like < or >) and invisible characters in HTML without breaking the browser parser. They begin with an ampersand (&) and end with a semicolon (;).
How does HTML entity encoding prevent Cross-Site Scripting (XSS)?
By escaping special characters (converting <script> to <script>), the browser renders the characters as plain text instead of executing them as live code, which mitigates injection vulnerabilities.
Can I decode HTML entities back to plain text?
Yes, the tool works bi-directionally. You can paste HTML-encoded strings to escape them, or paste raw text to decode them back.
Does it support both named and numeric HTML entities?
Yes, the tool supports named entities (like & or <) as well as decimal (&) and hexadecimal (&) character references.