Skip to content
FR – lire en français

HTML Entity Encoder

Escape text for HTML, or turn & and é back into characters.

Loading the tool on your device…

To show text such as <b> or a lone & on a web page, it has to be written as an entity. This tool escapes text so it shows as-is, and decodes entities back into characters while leaving real tags alone.

Updated 7 December 2026 · runs in your browser

How to use it

  1. Choose Encode or Decode.
  2. Paste your text or HTML.
  3. Copy the result.

Details

HTML Entity Encoder details
Encodes& < > " and ', plus accents and emoji if you ask
DecodesNamed entities (&eacute;), decimal (&#233;) and hex (&#xE9;)
SafetyDecoding never runs scripts or creates tags

Questions

Do my files leave my computer?
No. This tool runs inside your browser tab. The page makes no network request with your data, and you can check that yourself in your browser's developer tools.
Is escaping enough to stop XSS?
Escaping text placed between tags is the main defence, but text inside attributes, scripts or URLs needs other rules. Use your framework's built-in escaping where you can.