Skip to content

HTML Entity Encode/Decode

Free

Convert special characters to HTML entities and back

htmlentitiesencodedecodeescape
All Developer Tools

How it works

1

Enter

Type or paste text containing special characters or HTML entities into the input field.

2

Convert

Choose Encode to convert special characters to HTML entities, or Decode to restore the original characters.

3

Copy

Copy the result to safely embed in HTML documents or display decoded content.

Frequently asked questions

What are HTML entities?+
HTML entities are text codes that represent special characters in HTML. For example, &amp; represents &, &lt; represents <, and &quot; represents ". They prevent browsers from interpreting characters as markup.
Is my text processed on a server?+
No. All encoding and decoding runs in your browser. Your content never leaves your device, making it safe to process any text including code snippets or private content.
When should I use HTML entity encoding?+
Use it when displaying user-generated content in HTML to prevent XSS attacks, when showing code examples in web pages, or when your text contains characters like <, >, &, or quotes.
Does it handle named and numeric entities?+
Yes. The tool supports named entities like &amp; and &copy;, decimal numeric entities like &#169;, and hexadecimal entities like &#xA9;. All formats are correctly decoded.