All Tools › HTML Entity Encode/Decode

HTML Entity Encoder & Decoder

Escape special characters to HTML entities, or decode them back.

Escape and unescape HTML characters

Characters like <, >, and & have special meaning in HTML. To show them as text rather than have the browser interpret them as markup, they must be written as entities such as &lt;. This tool converts raw characters into their safe entity form and back again — essential when you want to display code samples or user text without it breaking the page.

How to use it

  1. Paste your text or HTML.
  2. Choose encode to make it display-safe, or decode to turn entities back into characters.
  3. Copy the result into your page or template.

Why it matters

Questions people ask

Is escaping the same as sanitising? Related but not identical — escaping makes text display literally; sanitising removes dangerous markup. For untrusted input, escaping output is a key defence.

Is my text uploaded? No — conversion runs in your browser.