HTML Decoder

html-tools

How to use the HTML Decoder

Decode HTML-encoded text in three steps:

1

Paste the encoded HTML

Enter or paste any HTML-encoded text containing entities like <, >, &, ", or numeric references like ©.

2

View the decoded output

The decoded text appears instantly in the Source tab showing the raw decoded characters and markup.

3

Switch to Preview

Click the Preview tab to render the decoded HTML visually in-browser — useful for confirming the decoded content displays correctly before using it.

4

Copy or download

Click Copy to grab the decoded text, or Download to save as an HTML file.


When to use this tool

Use this tool whenever you need to reverse HTML encoding or read encoded content:

  • Decoding HTML source code that has been double-encoded and appears as visible entity text instead of rendered HTML
  • Reading and inspecting HTML stored in databases, APIs, or CMS fields that return encoded strings
  • Reversing HTML encoding applied by email clients or content management systems to embedded code snippets
  • Debugging web scraping output where HTML entities appear as literal text in the extracted data
  • Converting encoded HTML templates back to editable source before making changes
  • Recovering readable content from XML or HTML data feeds that use extensive entity encoding

Frequently asked questions

Q:What types of HTML entities can this tool decode?
This tool decodes all three types of HTML entity references: named entities like  , ©, and é; decimal numeric references like © and é; and hexadecimal numeric references like © and é. It uses the browser's native HTML parser which supports the complete HTML5 named entity list — over 2,000 named entities in total.
Q:What is double-encoding and how do I fix it?
Double-encoding happens when already-encoded content gets encoded a second time. For example, &lt; (which represents <) gets encoded again to &amp;lt; — so instead of seeing a < bracket or the tag it belongs to, you see the literal text '&lt;' on screen. To fix it, run the text through this decoder once. If the output still contains entities, run it through a second time. This tool also indicates how many entities were found, so you can gauge how many decode passes are needed.
Q:Is it safe to use the Preview tab to render decoded HTML?
The Preview tab renders decoded HTML directly in the browser using dangerouslySetInnerHTML. This is intentional for inspection purposes — it shows exactly how the HTML would render. However, be cautious when previewing decoded content from untrusted sources, as it may execute embedded JavaScript. For untrusted content, use the Source tab only to read the decoded text without rendering it.
Q:Why does my decoded text still show entity-like text?
If your output still contains visible entity-looking text (like &amp;lt; or &amp;amp;), the content has been double-encoded — meaning it was encoded at least twice. Run it through this decoder a second time. Each decoding pass removes one layer of encoding. The entity count shown in the status bar tells you if entities remain after decoding.
Q:Can I decode HTML entities from an API or database response?
Yes — paste the raw string from your API response or database query result directly into the input. Many APIs (RSS feeds, REST endpoints returning HTML fields, CMSes like WordPress) return HTML with encoded entities. This tool decodes them back to readable text or usable markup. For programmatic use in JavaScript, the browser-native approach is: const el = document.createElement('textarea'); el.innerHTML = encodedString; return el.value;
Q:What is the difference between HTML decoding and URL decoding?
HTML decoding converts HTML entity references (&amp;lt;, &amp;#169;) back to characters — it operates on HTML markup and text content. URL decoding converts percent-encoded sequences (%3C, %26, %20) back to characters — it operates on URL strings and query parameters. They are separate encoding systems for different contexts. A string can be both HTML-encoded and URL-encoded simultaneously, requiring both to be decoded. Use our URL Decoder tool for percent-encoded strings.