ToolKit logoToolKit

Dev tools

HTML Entity Encoder/Decoder

Convert characters to HTML entities and decode entities back to text.

HTML entities

Encoded

body { color: red;   margin: 0; }

Decoded

body { color: red;   margin: 0; }

How to use the HTML Entity Encoder/Decoder

This tool converts characters into their HTML entities and decodes entities back into plain text. Encoding turns characters such as the angle brackets and ampersand into safe sequences like <, > and &, so they display literally on a page instead of being interpreted as markup and breaking your layout.

Developers use it to show code samples on a web page, to stop stray characters from corrupting the surrounding HTML, and to read entity-encoded content they have received from a feed or an API. Having both directions available in one place covers writing new content and debugging existing content equally well.

Encoding and decoding run in your browser with nothing uploaded, so the process is instant and private. There is no install and no account required, which makes it an easy tool to reach for the moment a character refuses to render the way you intended. Both encoding and decoding stay on your device, so any content you paste in remains private throughout.

Frequently asked questions

What are HTML entities?

HTML entities are escape codes such as &lt;, &gt; and &amp; that let you display reserved characters like <, > and & as text instead of having the browser interpret them as markup.

Can it both encode and decode?

Yes. Encoding converts characters to entities and decoding converts entities back to plain text — you can switch direction at any time.

Does it handle named and numeric entities?

Yes. It supports common named entities as well as numeric (decimal and hexadecimal) character references.

Is my text sent to a server?

No. Encoding and decoding happen entirely in your browser.