← All free tools Developer tools

HTML entity converter

Encode or decode HTML entities for any given input.

Convert

About this tool

The HTML entity converter encodes text so it shows up in a web page as written instead of being read as HTML, and decodes HTML entities back into normal characters.

How to use the HTML entity converter

  1. Choose Encode or Decode.
  2. Paste your text or HTML.
  3. Copy the result.

What encoding does

  • The five characters with a meaning in HTML become named entities: & is &amp;, < is &lt;, > is &gt;, " is &quot; and ' is &#39;.
  • Every other character outside plain ASCII becomes a numeric entity, so é is &#233; and “ is &#8220;.

So <a href="x">Café</a> becomes &lt;a href=&quot;x&quot;&gt;Caf&#233;&lt;/a&gt;, which a browser displays as the code itself.

When you need it

  • Showing code on a web page or in a blog post.
  • Putting user text into HTML safely, so it can’t add tags or scripts.
  • Old systems and emails that can’t handle characters outside ASCII.

Decoding understands named entities (&nbsp;, &copy;, &eacute;) as well as decimal and hex ones (&#169;, &#xA9;). It all happens in your browser.

Have a project in mind?

Have a brand or a product to grow?