Encode markup-significant characters
Named mode escapes the markup-significant characters and leaves the ordinary spaces visible.
Input text < & > Result < & >
Turn characters into HTML references, or decode references back into text. Tags stay visible as text in the result.
Your text is processed on your device. This tool has no third-party scripts, and GlyphIndex never reads your clipboard automatically.
JSON includes your input and the result. Keep the file private if the text is private.
CSV contains all inspection records. If the output exceeds 10,000 UTF-16 units, those records describe the input. Formula-leading cells start with an apostrophe; JSON keeps the exact text.
Choose a grapheme cluster to see its code points.
| Character | Code points | Standard name | UTF-8 bytes | UTF-16 units |
|---|
Named mode escapes the markup-significant characters and leaves the ordinary spaces visible.
Input text < & > Result < & >
One reference is hexadecimal and the other decimal. Both denote U+0041.
Input text A A Result A A
The decoded result is a literal string in a text field. No image element is created.
Input text <img src=x onerror=alert(1)> Result <img src=x onerror=alert(1)>
The surrogate reference remains literal and is reported. It is not silently converted to a replacement character.
Input text � Result � — invalid-scalar feedback
This converter uses explicit complete references. It does not emulate all HTML parser recovery rules.
Input text & Result & — missing-semicolon feedback
Hexadecimal mode represents every scalar, including ASCII characters.
Input text A♥ Result A♥
Named mode uses a single-character reference where one is available and hexadecimal notation otherwise. It leaves ordinary printable ASCII readable, apart from markup-significant punctuation. Hexadecimal and decimal modes encode every scalar, including letters and spaces.
Decoding handles one layer at a time: &lt; becomes <, not <. Check the intermediate result before deciding whether to decode again.
A semicolon is required. Unknown names, malformed numbers, out-of-range values, and surrogate references stay unchanged and are flagged. Numeric control values are flagged without the legacy remapping an HTML parser may apply.
The destination still matters. Inserting text into an HTML page differs from building a URL, script, or CSS value. Use the receiving system’s escaping method; entity conversion is not a complete HTML sanitizer.
Input is limited to 10,000 UTF-16 units, with a separate limit on expanded output. Unpaired surrogates in the input are rejected. Keep the original nearby when checking references that were left unchanged.
GlyphIndex · glyphindex.site · support@glyphindex.site