Free HTML Entity Encoder & Decoder
Something not working? Report a problem
About the HTML Encoder & Decoder
Encode special characters to HTML entities (&, <, >, &#x…) or decode them back to plain text — instantly in your browser with nothing uploaded.
How to use the HTML Encoder & Decoder
- 1Choose Encode to convert special characters to HTML entities, or Decode to reverse them.
- 2Type or paste your text into the input box — the result updates instantly.
- 3Click Copy to copy the output to your clipboard.
- 4Switch modes at any time; the input is preserved.
Frequently asked questions
What characters are encoded?
The five characters with special meaning in HTML: & → &, < → <, > → >, " → ", and ' → '. These are the minimum required to prevent XSS when inserting untrusted text into HTML.
What is HTML entity encoding used for?
Encoding special characters prevents them from being interpreted as HTML markup. It is essential when inserting user-supplied text into a web page and when displaying code examples.
Does it handle all HTML entities?
The encoder outputs only the five critical named entities. The decoder recognises named entities (&, <, >, ", '), decimal numeric references ({) and hex numeric references ({).
Is my text uploaded anywhere?
No. All encoding and decoding happens instantly in your browser — your text never leaves your device.