HTML Entity Encoder Decoder
HTML Entity Encoder Decoder is a free developer tool that runs directly in your browser with no account required.
About this tool
Escape HTML special characters into entities, or convert common entities back to plain characters. Useful when you need to display code samples on a web page or clean up text copied from rendered HTML.
How to use
- Paste your snippet into the Text field.
- Choose Encode to escape special characters, or Decode to convert entities back.
- Copy the converted result from the output.
Frequently asked questions
Which characters does Encode escape?
The five HTML-critical characters: & becomes &, < becomes <, > becomes >, double quote becomes ", and the apostrophe becomes '.
Does Decode handle every named entity?
No. Decode converts the same five common entities (&, <, >, ", ') back to characters. Named entities like © or numeric references beyond ' are left as-is.
When should I encode text?
Whenever untrusted or code-like text is inserted into HTML, for example showing a code example, embedding user input, or putting a value inside an attribute, so the browser displays it instead of interpreting it.
Will encoding twice break my text?
Double-encoding turns & into &amp;, which renders incorrectly. Encode once, and decode first if the text already contains entities.
Is anything transmitted while I convert?
No. Both directions are simple string replacements executed in your browser, with no network activity.