One-way tool: this page decodes only — entities → characters. To go the other direction (characters → entities), use the HTML Entity Encoder. Want both directions in one place? Try HTML Entities.
Decode HTML entities
Entities 0Valid 0Invalid 0Passes 0
Per-entity mapping
Every entity found in your input, in order — what it decoded to, its type, and its exact code point. Invalid entities are flagged with the reason.
#
Entity
→
Character
Type
Code point
Pass
Status
Decode something above to see the mapping.
Worked examples
Click any example to load it into the decoder. All outputs verified against the decode engine.
All 2,231 WHATWG HTML5 named entities. Type to filter by name; click Copy to grab the entity text.
Entity
Character
Code point
How the decoder works
Scan. The input is scanned left to right for &. Hex references (A), decimal references (A), and named entities (&) are recognized; the longest valid name wins, so ¬it; is never misread as ¬ + it;.
Validate. Each candidate is checked honestly: unknown names, empty digit runs, �, UTF-16 surrogates, code points above U+10FFFF, and numeric references missing their ; are reported as errors with the exact position — never silently dropped.
Resolve. Valid entities become characters via the full 2,231-entry WHATWG table. Legacy entities without a semicolon (&<>") decode too, unless followed by a letter, digit, or = (the spec's ambiguous-ampersand rule). C0/C1 control references like € map to their HTML5 replacement characters (€).
Repeat to fixpoint. Decoding repeats until the text stops changing (max 8 passes), so double-encoded input like &lt; fully resolves to <. The per-entity map shows which pass decoded what.
Private. Everything runs in your browser — zero network requests, zero uploads.
Frequently asked questions
What is the difference between named and numeric HTML entities?
decodes to U+00A0 NO-BREAK SPACE, not the regular U+0020 space — they look identical but are different characters. That is why a string containing never equals the same string with a plain space, why trim() will not remove it, and why it prevents line breaks in HTML layout. The per-entity map above shows the exact code point of every decoded entity so invisible differences like this never surprise you.
What does double-encoded HTML like < mean?
Double encoding happens when text is escaped twice: the character < becomes <, then its ampersand is escaped again into <. A single decode pass only gets you back to <. This tool decodes repeatedly until the text stops changing (up to 8 passes), so < fully resolves to <. Most online decoders stop after one pass and leave you with <.
What is the difference between this decoder and the HTML Entity Encoder?
Direction. This page is decode-only: it turns HTML entities into characters (< becomes <). To go the other way — characters into entities (< becomes <) — use the HTML Entity Encoder. For both directions in one two-way workspace, use HTML Entities. Keeping each direction on its own page keeps the interface focused and the search intent exact.
Why did my entity not decode? What counts as invalid?
This decoder reports invalid entities honestly instead of silently skipping them: unknown names (&bogus;), empty references (&#; and &#x;), null (�), UTF-16 surrogates (�), code points above U+10FFFF, and numeric references missing their trailing semicolon (A). A bare & followed by a space or end of text is left alone — that is valid text, not an entity. Legacy entities without a semicolon (& < > ") still decode, unless followed by a letter, digit, or =.
Does this decode every HTML5 named entity?
Yes — all 2,231 named character references from the WHATWG HTML standard, including the 106 legacy forms without a trailing semicolon (&, ©, and friends). If an &name; is not in that list, it is reported as an unknown entity with its exact position, so you can fix the typo instead of guessing.
How do I decode HTML entities in JavaScript or PHP — and is my input uploaded anywhere?
In JavaScript, the classic one-liner is: create a textarea element, assign your string to its innerHTML, then read back its value. In PHP, use html_entity_decode($s, ENT_QUOTES | ENT_HTML5, 'UTF-8'). Nothing you paste on this page leaves your device: it runs 100% client-side JavaScript with zero network requests, so decoding even sensitive markup is private by construction.
Related tools: HTML Entity Encoder (the reverse direction: characters → entities) · HTML Entities (two-way encoder & decoder workspace).
We use cookies and third-party services (including Google AdSense) to personalize content, analyze traffic, and serve relevant ads. By clicking "Accept", you consent to our use of cookies as described in our Privacy Policy.
Report an issue
2 taps, no typing needed — diagnostics are sent automatically.