HTML entity encoding, three modes, two radixes
HTML encoding replaces characters that have meaning inside markup with character references so the browser renders them as text instead of parsing them as HTML. The five reserved characters are &, <, >, ", and '. In default mode, only those five are escaped; every other character passes through unchanged.
Switch Mode to All Letters to escape every codepoint as a numeric reference, which is useful for obfuscation or for embedding text inside a context where you want the browser to never confuse it with markup. Switch to Named Entities to use the five readable names (&, <, >, ", ') instead of numeric references for the reserved set.
The Radix dropdown picks the numeric format. Decimal produces references like A; Hex produces A. Both forms are valid HTML5 and render identically. Toggle Skip Newlines off if you want literal \n and \r bytes to be encoded too (default leaves them as line breaks for readability).
How to use html encode text
- 1Paste or type your HTML or plain text into the input panel.
- 2The entity-escaped result appears in the output panel as you type.
- 3Pick Mode: reserved-only (default), all characters, or named entities.
- 4Pick Radix: decimal (
A) or hex (A). - 5Toggle Skip Newlines to keep or escape literal line breaks.
Keyboard shortcuts
Drive TextResult without touching the mouse.
| Shortcut | Action |
|---|---|
| Ctrl F | Open the find & replace panel inside the input Plus |
| Ctrl Z | Undo the last input change |
| Ctrl Shift Z | Redo |
| Ctrl Shift Enter | Toggle fullscreen focus on the editor Plus |
| Esc | Close find & replace, or exit fullscreen |
| Ctrl K | Open the command palette to jump to any tool Plus |
| Ctrl S | Save current workflow draft Plus |
| Ctrl P | Run a saved workflow Plus |
What this tool actually does
Default reserved-only mode escapes the five HTML special chars
In default mode, only &, <, >, ", and ' are escaped. Every other character (letters, digits, accented characters, emoji) passes through unchanged. The current Radix picks numeric form.
Mode = All Letters escapes every codepoint
Switches to escaping every character via numeric reference. Hello becomes Hello in decimal, or Hello in hex. Useful for obfuscation or strict-context embedding.
Mode = Named Entities uses readable names
Switches the five reserved characters to their named forms (&, <, >, ", '). Other characters pass through. Use this when you want HTML that reads naturally in source view.
Radix picks decimal or hex numeric form
Decimal produces A; hex produces A. Both are valid HTML5 and render the same character. Hex is more compact for high codepoints; decimal is more readable for ASCII.
Skip Newlines preserves line breaks in All mode
On by default. Leaves literal \n and \r bytes unencoded so the rendered HTML keeps its line layout. Turn it off to encode line breaks as or 
. Has no effect in reserved-only or named modes.
Worked example
Default mode, decimal radix: only the five reserved characters are escaped, the alphanumerics pass through. Switch Mode to Named Entities for <p>Hello & welcome!</p>.
<p>Hello & welcome!</p>
<p>Hello & welcome!</p>
Settings reference
| Behaviour | Effect on output |
|---|---|
Mode = HTML Reserved Only |
Default. Only & < > " ' are escaped, in the chosen Radix. |
Mode = All Letters |
Every character escapes to a numeric reference, in the chosen Radix. |
Mode = Named Entities |
The five reserved characters use named forms (&, <, etc.); other characters pass through. |
Radix = Decimal |
Numeric references take the form A. |
Radix = Hex |
Numeric references take the form A. Both forms render identically in browsers. |
| Skip Newlines | On by default. In All Letters mode, leaves \n and \r as literal line breaks. Off encodes them too. |
| Alphanumerics in default mode | Pass through unchanged. Accented characters and emoji also pass through. |
FAQ
Which mode should I use for safely embedding user input?
HTML Reserved Only mode with Decimal or Hex radix. That escapes the five characters that affect HTML parsing and leaves everything else alone, which is what every standard library does.What is the difference between named entities and numeric references?
&, <) read better in source view; numeric references (&, <) work for any character including ones that have no name. HTML5 has hundreds of named entities; this tool emits only the five reserved ones in named mode.Why does the apostrophe escape to ' by default?
All Letters modes, the apostrophe escapes to its numeric reference (' decimal or ' hex) for compatibility. Switch to Named Entities mode to get ' instead, which is HTML5-only and not supported in HTML4 / XHTML1.Does it escape line breaks?
All Letters mode with Skip Newlines turned off. By default, \n and \r pass through as literal whitespace, which keeps the rendered output readable.