TEXT & DEVELOPER / FREE BROWSER TOOL

Escape HTML

Escape special HTML characters in plain text.

Files are processed in this browser and are not uploaded to YYY Tools.Details
Opening workspace

About Escape HTML

Use the HTML escape tool when you want to show markup characters as plain text. It can convert special characters to HTML entities for &, <, >, double quotes, and apostrophes. This is a small text transformation, not an HTML sanitizer or a complete security policy.

How to escape HTML characters in text

  1. Paste the plain text containing markup characters.
  2. Select Process to replace the supported special characters.
  3. Review and copy the escaped text for the appropriate rendering context.

A practical example

Input
<b title="x">A&B</b>
Result
&lt;b title=&quot;x&quot;&gt;A&amp;B&lt;/b&gt;

The output displays markup as text when interpreted in an appropriate HTML text context; it does not retain a live bold element.

Supported input and limitations

  • Only the five listed characters are escaped. Decoding entities, preserving a subset of safe HTML, and stripping tags are not included.
  • Correct escaping is context-specific. This output alone does not secure JavaScript, URLs, CSS, SQL, or every HTML attribute context.

Processing happens on your device. Read about local processing and optional workspace recovery.

Frequently asked questions

Is HTML escaping the same as sanitizing HTML?

No. Escaping represents characters as text. Sanitization parses markup and applies a policy to allowed elements and attributes.

Why does an existing ampersand entity get escaped again?

The input is treated as plain text. For example, &amp; becomes &amp;amp;. Avoid applying this transform repeatedly without understanding the output context.

Related tools