HTML Entity Encoder & Decoder Online
Paste text or HTML into the box, then click Encode to turn special characters like &, <, >, and quotes into HTML entities, or Decode to turn entities back into readable characters. It all runs in your browser — nothing is uploaded.
Named, decimal and hex entity forms
Only a fixed list of named entities exists, while numeric forms work for any Unicode code point. A browser draws the same glyph for each spelling in a row below.
| Character | Named | Decimal | Hex |
|---|---|---|---|
| & | & | & | & |
| < | < | < | < |
| > | > | > | > |
| " | " | " | " |
| ' | — | ' | ' |
Double-encoded entities and framework escaping
Escaping the ampersand after the other characters breaks the output. A < first becomes <, then the ampersand pass turns it into &lt;, and the page shows the literal text < where a bracket was expected.
React and Vue escape rendered values by default. That protection disappears once code assigns to innerHTML, concatenates an HTML string by hand, or uses a raw template. In those cases the escaping has to be done explicitly.
Frequently asked questions
- What does the non-ASCII option do?
- It converts every character above the basic ASCII range, such as accented letters, Cyrillic, CJK and emoji, into a hexadecimal numeric entity like 😀. That helps when a system accepts only plain ASCII, like some older email templates.
- Why does Decode leave < in my text?
- Because the text was encoded twice. Decode removes one level at a time: &lt; becomes <, and pressing Decode again gives the bracket. Names the decoder does not know, such as &bogus;, are left exactly as they are.