What it does
HTML gives &, <, >, " and ' special meaning, so text dropped into a page or an attribute has to be escaped. This tool escapes and unescapes as you type.
Encode
- Special chars escapes only the five characters that matter for HTML. This is what you want for templates and is the safe default.
- + Non-ASCII also turns every character outside ASCII into a reference, useful for emails, legacy systems or files that must stay 7-bit.
- Choose Named (
é, falling back to a number where no common name exists), Decimal (é) or Hex (é) references. Emoji and other characters beyond the Basic Multilingual Plane become one correct reference, not two broken surrogate halves. - Turn off Escape quotes for text that only goes between tags.
Decode
Decoding uses your browser’s own HTML parser, so every named entity the HTML standard defines (more than 2,000) is supported, along with decimal and hex references. Markup is never executed. The tool tells you about unknown entities and entities missing their semicolon, with line and column, and warns when the input was escaped twice (&amp;).
How to use it
Pick Encode or Decode, paste your text, and copy the result with Copy or Ctrl+Enter. Swap feeds the output back in.
Privacy
Nothing leaves your browser. Your last input is kept in local storage; Clear removes it.