HTML Encode

HTML Encode

Encode markup so it can be shown as text in HTML.

Try this example

Encode the sample. The angle brackets and ampersand become HTML entities.

<p>Tea & coffee</p>

Expected result

&lt;p&gt;Tea &amp; coffee&lt;/p&gt;

Choose this when displaying markup as a literal example in HTML text. Other output contexts can require different escaping.

Related walkthrough · When to Format or Minify HTML, CSS and JavaScript


Avatar

DTool Team

Product Team

We build simple, reliable browser tools that make everyday digital work faster.

Cookie
We care about your data and would love to use cookies to improve your experience.

Learn how we use cookies