ENCODING WORKSPACE
HTML Entity Encoder / Decoder
Encode or decode HTML entities as text.
Input is processed on this site only when you run the tool. The application does not save inputs or results.
input.txt
Result result.txt
A little clarity goes here.
Run the tool to see your result.
Result preview
UTF-8 text, at most 262144 bytes per input. Tab leaves the editor. Plain text disables syntax colors. Browser textareas may normalize line endings to LF.
{"encode":{"inputMode":"text","options":[]},"decode":{"inputMode":"text","options":[]}}{"encode":{"input":"<p>A & B<\/p>","output":"<p>A & B</p>","options":[]},"decode":{"input":"<p>A & B</p>","output":"<p>A & B<\/p>","options":[]}}A QUICK WALKTHROUGH
A familiar workflow,
with room to focus.
Paste text with special characters, or HTML5 entities.
Choose Encode or Decode.
Inspect the result as text. Markup is never rendered as a page.
When to use HTML Entity Encoder / Decoder
Turn literal markup characters into text escapes for inspection, or decode supported entity text while debugging a template.
Read the result
Copy the text for the intended context. Entity encoding alone is not a universal HTML, JavaScript, CSS or URL sanitizer, and the output is never rendered as an HTML preview.
SEE IT IN PRACTICE
Worked examples
Sample input. A result you can inspect.
Encode example
Input
<p>A & B</p>
Expected result
<p>A & B</p>
Decode example
Input
<p>A & B</p>
Expected result
<p>A & B</p>
Formats, limits and common errors
Check the entity name/number and terminating semicolon. Decoded text can still contain unsafe markup for other applications.
- Uses PHP HTML5 named entities with quoted characters encoded. Existing entities encode again deliberately.
- Decoding is a single pass and is not HTML validation or sanitization. Unknown entities remain text.
- Entity expansion can exceed the shared output ceiling.
- Input: 262,144 UTF-8 bytes per text field. Output: at most 524,288 UTF-8 bytes; serialized responses have a separate 1 MiB ceiling. Size/work failures return no partial result.