Helpful Toolbox

HTML Entity Encoder and Decoder

Convert text to safe HTML entities or turn entities back into plain characters β€” instantly and entirely in your browser.

πŸ“– How it works & FAQ

What HTML entities are

Certain characters carry special meaning in HTML. A left angle bracket (<) starts a tag, an ampersand (&) starts an entity, and quotation marks close attribute values. If you drop raw text containing these characters into a page, the browser may misread it β€” breaking your layout or, worse, opening the door to script injection. HTML entities are safe stand-ins: &lt; renders a literal <, &amp; renders a literal &, and &#39; renders an apostrophe. Encoding swaps the risky characters for these codes; decoding reverses the process so you can read the original text.

Encode, decode, and non-ASCII

Encode mode converts the five reserved characters β€” &, <, >, double quote, and single quote β€” into their entity forms. Tick "Encode all non-ASCII" to also turn accented letters, emoji, and other symbols into numeric entities like &#233;, which is handy for older systems or strict ASCII-only pipelines. Decode mode accepts named entities (like &copy;), decimal entities (&#169;), and hex entities (&#xA9;) and returns the plain characters.

How to use it

  1. Pick Encode or Decode from the Mode menu.
  2. When encoding, optionally tick Encode all non-ASCII for numeric entities.
  3. Type or paste your text into the input box β€” the result updates as you type.
  4. Click Copy result to grab the output, or Swap to feed it back and reverse the conversion.

FAQ

Is my text sent anywhere?
No. Everything runs in your browser with JavaScript. Nothing is uploaded or stored on a server.
Which characters get encoded?
By default only &, <, >, and both quote styles. Enable the non-ASCII option to also encode any character above code point 127.
Does decoding handle named and numeric entities?
Yes β€” named (&nbsp;), decimal (&#160;), and hexadecimal (&#xA0;) entities all decode correctly.
Is single-quote encoding safe for attributes?
Yes. Encoding apostrophes as &#39; keeps text safe inside single-quoted HTML attribute values.