HTML Entity Escape

Input

Output

0

Input chars

0

Input bytes

0

Output length

0

Entities

Entity Reference (0)

No entities detected

About HTML Entity Escape

Browser-based HTML entity escape and unescape tool

Convert HTML special characters to entity encoding, or restore entity-encoded text back to original characters. Supports the full HTML5 named entity table and numeric entities, with batch processing and entity reference table.


Features

  • Smart escaping with 250+ HTML5 named entities
  • Unescape support for named, decimal, and hexadecimal numeric entities
  • Smart mixed output: named entities first, hexadecimal fallback
  • Batch mode: process each line independently
  • Entity reference table: real-time mapping of detected entities to characters
  • Input/output statistics: character count, byte count, output length, entity count
  • All processing done locally in your browser — no data uploaded

How to Use

  1. 1Select Escape or Unescape mode
  2. 2Paste or type text in the input area
  3. 3Results are calculated and displayed in real time
  4. 4Click the entity reference table to view detected entity mappings
  5. 5Use the Swap button to quickly reverse input/output and switch mode

FAQ

What are HTML entities?
HTML entities are encoding representations for special characters in HTML documents, starting with & and ending with ;, such as &amp; for & and &lt; for <. They prevent characters from being parsed as HTML tags or attributes.
When should I use HTML entity escaping?
Use HTML entity escaping when you need to display text containing <, >, & and other special characters in HTML, or to prevent XSS injection when embedding user input into HTML context, such as inside <code> and <pre> tags.
What's the difference between named and numeric entities?
Named entities use predefined names like &copy; for ©, which are more readable. Numeric entities use Unicode code points like &#169; (decimal) or &#xA9; (hexadecimal), which cover all characters but are less readable.
What is batch mode for?
Batch mode processes each line of input independently, suitable for scenarios where you need line-by-line escaping/unescaping, such as processing multi-line HTML content in log files. Lines don't affect each other.
What happens with unrecognized entities during unescaping?
The tool automatically recognizes all HTML5 standard named entities and numeric entities. Unrecognized named entities (like &foo;) are passed through unchanged without conversion.

Related Tools

Code FormatterXML FormatterUnicode ConverterColor Code ConverterBase ConverterBase64 Encoder DecoderURL Encoder DecoderCookie to JSONJSON Unicode EscapeMD5 EncoderJWT Decode Verify EncodeJSON to CookieUUID Generator & ParserRegex TesterHTTP Status CodesPort NumbersASCII TableUser-Agent ViewerMy Browser FingerprintJSON Unicode UnescapeCron Expression Generator & ParserIP Address LookupHash CalculatorSQL Formatter