DevKit Labs

HTML Entity Encoder & Decoder

Encode text to HTML entities or decode them back — including named and numeric entities, 100% in your browser.

Text
HTML entities

About HTML Entity Encoder & Decoder

Switch between Encode and Decode to convert instantly. Encoding always escapes the characters that matter for HTML — &, <, >, " and ' — and an option escapes every non-ASCII character as a numeric entity too. Decoding resolves both named entities (like &amp; and &copy;) and numeric ones (&#169; or &#xA9;).

Decoding uses the browser's own HTML parser, so the full set of named entities is supported, while tags are kept as literal text and nothing is executed. Everything runs locally; your text is never uploaded.

Escape HTML-special characters

Input
<a href="x">Tom & Jerry</a>
Output
&lt;a href=&quot;x&quot;&gt;Tom &amp; Jerry&lt;/a&gt;

Decode reverses it, and “Escape all non-ASCII” also encodes accents and emoji.

Frequently asked questions

Which characters get encoded?

Always &, <, >, double and single quotes. With “Escape all non-ASCII” on, every character above ASCII (accents, symbols, emoji) is also encoded as a numeric entity.

Does decoding support named entities?

Yes. Decoding uses the browser's HTML parser, so named entities like &copy; and &mdash; and numeric ones like &#8212; all resolve correctly.

Is it safe to decode untrusted HTML here?

Decoding resolves character references only; tags are treated as literal text and no scripts run, and nothing leaves your browser.

Is my data uploaded anywhere?

No. All encoding and decoding happen locally in your browser.

Related tools