How HTML Entity Encoder / Decoder Works
Encoding replaces characters that have special meaning in HTML — &, <, >, " and ' — with their named entity equivalents, so they display as literal text instead of being interpreted as markup. Decoding looks up named entities (like &) and numeric entities (like & or &) and converts them back to the original characters.
How to Use This Tool
- Choose Encode or Decode.
- Paste your text or HTML snippet into the input box.
- Select Convert.
- Copy the result from the output box.
Example
Encoding Tom & Jerry's "Chase" produces Tom & Jerry's "Chase". Decoding 5 < 10 produces 5 < 10.
Helpful Tips
- Encode text before inserting user-submitted content into HTML by hand, so it can't be misread as markup.
- Decoding supports both named entities (like ©) and numeric entities (like © or ©).
Frequently Asked Questions
Why would I need to encode these characters?
In HTML, characters like < and & have special meaning. If they appear literally in page content without encoding, browsers may misinterpret them as the start of a tag or entity instead of displaying them.
Does decoding execute any HTML or scripts?
No. Decoding is done with a plain text lookup table for entity names and codes — it never inserts anything into the page's DOM, so it's safe to decode untrusted text.
Is my text sent anywhere?
No, both encoding and decoding happen entirely in your browser.
This tool runs entirely in your browser. Your input is not uploaded to any server.