Home โ€บ Developer Tools โ€บ HTML Entity Encoder / Decoder

๐Ÿท๏ธ HTML Entity Encoder / Decoder

Encode special characters into HTML entities, or decode entities back to plain text.

About this HTML Entity Encoder / Decoder

HTML reserves characters like <, > and & โ€” if you want them to appear as visible text on a web page you must write them as entities such as &lt; and &amp;. This tool encodes those characters (plus quotes and non-ASCII characters as numeric entities) and decodes entities back to normal text, which is essential when editing templates, writing documentation or showing code samples on a page.

How to use it

  1. Paste the text or HTML you want to convert.
  2. Click Encode to turn special characters into entities.
  3. Or click Decode to turn entities back into readable characters.
  4. Copy the result from the box below.

Example

Encoding the text 'Fish & Chips <3' gives 'Fish &amp; Chips &lt;3', which a browser displays exactly as typed instead of treating < as a tag.

Frequently asked questions

Why encode non-ASCII characters too?

Numeric entities like &#169; for ยฉ render safely even in files saved with old or mismatched character encodings.

Does decoding handle named entities like &copy;?

Yes โ€” decoding uses the browser's own HTML parser, so every standard named and numeric entity is understood.

More Developer Tools