HTML Escape/Unescape

Encode special characters to HTML entities and decode them back. Batch processing, instant results.

Input
Characters: 0 Lines: 0 Entities found: 0
Output

Entity Reference Table

EntityCharacterDescription
&&Ampersand
&lt;<Less than
&gt;>Greater than
&quot;"Double quote
&#39;'Single quote (apostrophe)
&nbsp; Non-breaking space
&copy;©Copyright
&reg;®Registered trademark
&trade;Trademark
&mdash;Em dash
&ndash;En dash
&euro;Euro sign
&pound;£Pound sign
&yen;¥Yen sign
&cent;¢Cent sign
&times;×Multiplication sign
&divide;÷Division sign

Frequently Asked Questions

What is HTML escaping?
HTML escaping converts special characters like <, >, &, ", ' into HTML entities so they display correctly in web browsers instead of being interpreted as HTML markup.
What characters need to be escaped in HTML?
The five characters that must be escaped in HTML are: < (less than) becomes &lt;, > (greater than) becomes &gt;, & (ampersand) becomes &amp;, " (double quote) becomes &quot;, and ' (single quote) becomes &#39;.
What is the difference between HTML escape and URL encoding?
HTML escaping converts characters to HTML entities (like &lt;) for safe display in web pages, while URL encoding converts characters to percent-encoded format (like %3C) for safe transmission in URLs. They serve different purposes.
Can I batch process multiple lines at once?
Yes, simply paste multiple lines of text into the input area and all lines will be escaped or unescaped at once. Each line is processed independently.
Why does my HTML break when I paste code snippets?
When you paste HTML code directly into a webpage, the browser interprets it as actual HTML tags. You need to escape it first so the angle brackets and special characters are displayed as text instead of being rendered as elements.
What is an HTML entity?
An HTML entity is a sequence of characters starting with & and ending with ; that represents a special character. For example, &lt; represents <, &nbsp; represents a non-breaking space, and &copy; represents ©.
Is this tool free to use?
Yes, this HTML escape/unescape tool is completely free with no registration required. All processing happens in your browser — your data never leaves your device.
Does this tool support named entities like © and ™?
Yes, the unescape function supports all standard HTML named entities including &copy; (©), &trade; (™), &reg; (®), &mdash; (—), and many more. The escape function converts characters to their minimal entity form.

Related Tools