HTML Entity Decoder
Decode HTML entities instantly. Convert & < > " and numeric entities back to readable characters. Free, 100% client-side.
How HTML Decoding Works
HTML decoding reverses the entity-encoding process defined in the HTML Living Standard. When a browser or server encodes special characters for safe embedding in HTML markup, it replaces them with entity references. Decoding converts those references back to their original characters.
Entity Types
There are three types of HTML entities. Named entities use a human-readable keyword: & for &, < for <, © for the copyright symbol. Decimal numeric entities use the Unicode code point in base-10: © for the copyright symbol. Hexadecimal numeric entities use the code point in base-16: © for the same character. HTML5 defines 2,231 named character references covering Latin, Greek, mathematical, and symbol characters.
The Decoding Algorithm
This tool uses the browser's native HTML parser via a temporary DOM element. When HTML content is assigned to an element's innerHTML, the browser automatically resolves all entity references to their character values. Reading the element's textContent then returns the decoded plain text. This approach handles every entity defined in the HTML specification, including multi-byte UTF-8 sequences and supplementary Unicode planes.
When to Use HTML Decoding
Common use cases include extracting readable text from API responses that return HTML-encoded data, processing web-scraped content for text analysis, converting HTML email content to plain text, and debugging encoded strings in log files. Always keep data HTML-encoded when inserting into HTML documents to prevent cross-site scripting (XSS) attacks.
Frequently Asked Questions
What is HTML decoding?
HTML decoding converts entities back to original characters. & → &, < → <, > → >, " → ".
What are HTML entities?
Special sequences for characters with meaning in HTML. Named (&) and numeric (©). HTML5 defines 2,231 named references.
When to decode?
When processing HTML for plain text display or API responses with HTML-encoded data. Do NOT decode when inserting into HTML — keep encoded to prevent XSS.
Is it safe?
Decoding is safe. The risk is inserting decoded content into HTML without re-encoding. Always encode output for HTML context.
Is this tool free?
Yes. All KappaKit tools are free, run in your browser, and require no signup or account.