HTML Entity Encoder/Decoder

Convert special HTML characters to and from entities.

HTML text input

Enter text to convert to HTML entities locally.

Encoded HTML outputRead-only

Conversion output appears here.

Read-only output remains selectable and can be copied manually.

Options

Operation

Encoding converts HTML-sensitive characters to entities. Decoding recognizes common named entities plus decimal and hexadecimal numeric entities.

Statistics

Input: 0 characters · 0 B · 0 lines

Output: 0 characters · 0 B · 0 lines

Encoded entities: 0

Decoded entities: 0

How to use

  1. Choose HTML Encode or HTML Decode.
  2. Enter text or paste HTML entities.
  3. Copy, download, or swap the output into the opposite operation.

Supported entities

Encoding converts &, <, >, double quotes, and apostrophes. Decoding supports common named entities, including &amp;, &lt;, &gt;, &quot;, and &apos;, plus decimal and hexadecimal numeric entities such as &#60; and &#x3C;.

Invalid entities and privacy

Unknown or malformed entities are kept as entered. Your text never leaves your browser: conversion, copying, and downloads all happen locally.

Frequently asked questions

Which characters are encoded?

The tool encodes ampersands, angle brackets, double quotes, and apostrophes so they can be represented safely as HTML entities.

Can I decode numeric entities?

Yes. Decimal entities such as &#60; and hexadecimal entities such as &#x3C; are decoded when they represent valid Unicode code points.

What happens to unknown entities?

Unknown or malformed entities are left unchanged, so the tool does not silently alter input it cannot recognize.

Will Unicode, emoji, or line breaks change?

No. The conversion changes only recognized HTML entities and preserves other characters, whitespace, line breaks, and case.

Practical guide

When to use it

Use it when literal text needs to be shown safely inside HTML markup, or when entity-filled copied source needs to become readable text.

Three steps

  1. Choose HTML Encode or HTML Decode.
  2. Paste text or entity references such as &lt; and &amp;.
  3. Convert and copy the result into the relevant HTML context.

Example and a common mistake

The literal text <strong> becomes &lt;strong&gt; so it can be displayed rather than interpreted as a tag.

Entity encoding helps represent text in HTML; it is not a complete solution for untrusted HTML or script-safety policies.

Encoding

Available

Unicode Converter

Convert Unicode characters, escapes, and code points.

Encoding

Available

ASCII Converter

Translate text between ASCII characters and numeric codes.