Skip to content

HTML Entity Encoder and Decoder

Escape HTML text characters or decode common named and numeric entities locally, rendering results as inert text.

Use the html entity encoder and decoder

Up to 100,000 characters. Invalid Unicode numeric entities are rejected. Only the named entities listed above are decoded.

Result

Enter values, then select the action button.

How it works

Encoding replaces ampersand, less-than, greater-than, double quote, and apostrophe. Decoding makes one pass over numeric entities and amp, lt, gt, quot, apos, and nbsp; unsupported named entities stay unchanged. Output is displayed as text. This is not an HTML sanitizer or a JavaScript/CSS escaping tool.

Worked examples

How to use this tool

Enter your values in the labeled fields, choose the units or mode where shown, and select the action button. Review the method and limits above. Reset restores the example inputs.

What happens to my input?

Calculations run locally in your browser. This tool does not upload your entries, fetch external data, or store input in your URL. See our privacy policy for website-wide details.

Found an issue or need another feature? Suggest an improvement.