HTML Encode Online

Simple HTML Encoding and Decoding Tool

Simply copy and paste your HTML text and click "Encode" or "Decode" button.
HTML encoding or decoding runs on client side and no data is sent to server.





Encode/decode non-ascii characters

Why do you need HTML encoding?

HTML encoding replaces special characters in HTML such as <, > with reserved HTML entities that are recognized by the HTML engine. Most common cases of using HTML encoding is when you want to display HTML special characters as text in your HTML element content. For example, if you want to display < within your div element, you need to encode (or escape) < character by replacing it with &lt;.

What is "Encode/decode non-ascii characters" option?

"Encode non-ascii characters" option above is used if you want to encode non-ascii characters to unicode code points in &#nnnn; format. If a web page is using UTF-8 character encoding, this option is not needed. But sometimes when a web page is not using UTF-8 but there is a need to display UTF-8 characters, this option can be used to preserve those unicode strings. Also when decoding, this option can be used to decode unicode code points back to non-ascii characters.