HTML Encoder / Decoder

Show markup as text or turn entities back into readable characters. Choose how aggressively to escape, and preview the rendered output inside a fully sandboxed frame.

Settings

Operation
Encoding depth

Input

Output

Rendered preview

The preview runs in a fully sandboxed frame with scripts disabled.

Useful for safely showing markup inside a page or an email template.
All processing is done locally in your browser. Your images never leave your device.

How to use

  1. 1

    Choose encode or decode.

  2. 2

    Select the encoding depth you need.

  3. 3

    Paste your HTML or entity-encoded text.

  4. 4

    Copy the result or check the rendered preview.

Supported formats

Accepts

Produces

FAQ

Escaping prevents user text from being interpreted as markup, which is the basic defence against cross-site scripting.

Basic escapes only the five critical characters, non-ASCII also escapes characters outside ASCII, and all escapes every character as a numeric entity.

Yes. Named, decimal and hexadecimal entities are all decoded, using the browser's own HTML parser.

Yes. It renders in an iframe with an empty sandbox attribute, so scripts, forms and same-origin access are all disabled.

Yes, in both directions, including characters made of multiple code points.

About this tool: HTML Encoder / Decoder

Escape HTML entities, safely

The HTML Encoder/Decoder converts characters into their HTML entity form (& → &amp;, < → &lt;, quotes into their named or numeric equivalents) and back. It is the correct way to display code on a page or to embed user text inside HTML without creating injection holes.

Four characters break HTML: <, >, & and quotes. Rendering user input without escaping them is the textbook cross-site scripting vulnerability; pasting code samples into a CMS without entities mangles them into invisible markup. Encoding solves both directions of the problem deterministically.

Conversion runs locally in your browser with both named-entity and numeric modes. Paste the text or snippet, choose a direction, and copy the safe output — the fastest way to make arbitrary text survive inside HTML.

Like every Piclizer tool, this one runs entirely in your browser — your files stay on your device.

Related tools