ZapToolbox

HTML Entity Encoder / Decoder

Escape text so it displays safely inside HTML, or turn entities like < and ₹ back into normal characters.

🔒 Runs entirely in your browser — nothing you type is uploaded.

How to use the HTML Entity Encoder / Decoder

  1. Paste text or HTML.
  2. Click Encode to escape it, or Decode to turn entities back into characters.
  3. Copy the output.

About this tool

In HTML, < starts a tag and & starts an entity, so to show those characters as text — for example when publishing a code snippet in a blog post — they must be written as &lt; and &amp;. Escaping user text before inserting it into a page is also a basic defence against cross-site scripting (XSS).

Decoding understands named entities (&nbsp;, &copy;, &hellip;), decimal (&#8377;) and hex (&#x20B9;) forms. It uses the browser’s HTML parser without running any scripts.

Frequently asked questions

Which characters must be escaped in HTML?

Always & and <. Also > and quotes (" and ') inside attribute values. Encoding all five is the safe default.

What is &nbsp;?

A non-breaking space — a space that prevents a line break between two words, like “₹ 500”.

Do I need to encode Hindi or emoji?

Not if your page uses UTF-8 (almost all do). Tick the option only for systems that require pure ASCII.