Skip to content
Input
HTML or text
Modes
2 explicit
Runtime
Browser

Encode text as HTML character references

Turn literal text characters into named or numeric references without parsing markup.

Local processingNo sign-upNo resource loading

Encode HTML entities

Source stays in this tab. Parser input is capped at 500 KiB; sanitizing uses 256 KiB.

Encoded character references

Every result is inert, copyable source or data, never live DOM.

What this tool does

Explicit-mode, bounded, local parsing

Encoding is a text transform, not a complete contextual escaping strategy. Attribute, URL, CSS, and JavaScript contexts have additional requirements.

Character encoding is context-sensitive

Encoding is a text transform, not a complete contextual escaping strategy. Attribute, URL, CSS, and JavaScript contexts have additional requirements.

The parser runs locally with a 500 KiB input cap, 100,000-node and 100-level tree limits, and a 1 MiB output cap. It never fetches URLs, loads resources, uploads source, or saves a preset.

Explicit document and fragment modes

Document mode applies the HTML document parser and may supply implied html, head, or body structure. Fragment mode parses only a pasted fragment. The selected mode is part of the result and is never inferred from the text.

Primary references

Questions and answers

Related HTML tools