Skip to main content

HTML Decoder

Replace HTML 4 named character references and decimal or hex numeric references with the characters they stand for. Names are case-sensitive (Ω is not ω). Unknown names are left unchanged.

Rated 4.7 out of 5 based on 300 reviews

Input
Output

How to HTML-decode

  1. Paste entity-encoded text in Input.
  2. Read the decoded string.
  3. Unknown named entities are left unchanged.
  4. Encode on the HTML encoder for the reverse. Do not inject decoded output as HTML unless you trust it.

HTML entity decode

Named HTML 4 references plus numeric character references

Named setHTML 4 names as in js-htmlencode 0.3.0 (case-sensitive)
Numeric&#NNN; and &#xHH; via Unicode code points
nbspDecodes to U+00A0 (non-breaking space)
Unknown namesLeft as written

What this decoder accepts

It reverses HTML 4 named character references (amp, lt, copy, euro, Greek letters, arrows, and the rest of that table) plus decimal and hexadecimal numeric character references. The named table matches js-htmlencode 0.3.0 from emn178 Online Tools, with   decoded to U+00A0 rather than ASCII space. It does not run HTML as a document and does not execute scripts.

Case and numeric forms

Named entities are case-sensitive: Ω is Greek capital omega, ω is small omega. Numeric forms are © (decimal) and © (hex). References must end with a semicolon. Unknown names stay in the text.

Decoded markup is still markup

Decoding <script> yields a less-than, the word script, and a greater-than. If you then inject that string as HTML, it can become a tag. Pair with the HTML encoder. This decoder is not a sanitizer.

HTML decode questions

Does this page upload what I type?
No. The work runs in the page you opened. CZNull does not receive the input.
Will © decode?
Yes. Copyright, euro, nbsp, and the rest of the HTML 4 named set decode. Names are case-sensitive.
Double encoded?
Run decode twice if the source escaped twice. < becomes < on the first pass.
Does it parse a full HTML document?
No. It only replaces &...; references in the string.
Why did a name stay as text?
It is not in the HTML 4 table, the semicolon is missing, or the spelling differs by case.