How to use this tool
Paste text and choose Encode to escape HTML special characters, or Decode to turn supported named and numeric entities into text. Select the encoding policy before handling text that already contains entities. Copy or swap the output, or clear the tool.
How it works
Encoding replaces HTML-sensitive characters with character references. Decoding recognizes named HTML references and decimal or hexadecimal numeric references without interpreting the resulting text as HTML. Output is always displayed as plain text.
A QUICK EXAMPLE
Put it into practice.
<div>Hello & Welcome</div> encodes as <div>Hello & Welcome</div>. The reference 😀 decodes to a smiling emoji.
Good to know
Encoding mode and named-reference decoding are separate choices. Existing valid references are preserved by the default encoding policy; use explicit double encoding when literal entity syntax must be escaped. Unknown or incomplete references follow the documented policy shown beside the controls. This is a text conversion tool, not an HTML sanitizer.
Common questions
Can decoded HTML execute?
No. Input and output are handled as text, never inserted as executable HTML. Do not treat decoding as sanitization when using the result in another application.