Search tools

Parse HTML: Escape, Encode and Decode

Paste code to parse (escape) HTML so it shows as text in a Blogger or WordPress post: < becomes &lt;, > becomes &gt; and & becomes &amp;. The same box encodes and decodes URLs, Base64, JavaScript strings and Unicode escapes, all in your browser.

Updated By Rules verified 2026-10-19What each mode does

Encode or decode

49 → 79 characters

Advertisement

How to parse HTML for a Blogger post

  1. Paste the code you want to show (HTML, CSS, JavaScript or an AdSense snippet).
  2. Keep HTML entities and Encode, and tick Wrap in a code block.
  3. Copy the output.
  4. In Blogger, open the post in HTML view and paste where the code should appear.
  5. Preview the post: the code shows as text, with spaces and line breaks kept.

What each mode does

The same input in each format, encoded by the tool
ModeEncodedUse it for
HTML entities&lt;a href=&quot;/menu?item=kopi&amp;size=L&quot;&gt;Kopi &amp; teh ☕&lt;/a&gt;Showing code in Blogger or WordPress posts, HTML attributes
URL%3Ca%20href%3D%22%2Fmenu%3Fitem%3Dkopi%26size%3DL%22%3EKopi%20%26%20teh%20%E2%98%95%3C%2Fa%3EQuery string values, links with spaces or Malay/Chinese text
Base64PGEgaHJlZj0iL21lbnU/aXRlbT1rb3BpJnNpemU9TCI+S29waSAmIHRlaCDimJU8L2E+Data URLs, email attachments, APIs that need text
JavaScript / JSON string<a href=\"/menu?item=kopi&size=L\">Kopi & teh ☕</a>Putting text inside a JavaScript or JSON string
Unicode \u escapes<a href="/menu?item=kopi&size=L">Kopi & teh \u2615</a>Source code and JSON that must stay ASCII

Advertisement

Common HTML entities

Characters and their entities
CharacterNamedNumeric
<&lt;&#60;
>&gt;&#62;
&&amp;&#38;
"&quot;&#34;
'&apos;&#39;
(non-breaking space)&nbsp;&#160;
©&copy;&#169;
’&rsquo;&#8217;
—&mdash;&#8212;
…&hellip;&#8230;
€&euro;&#8364;
×&times;&#215;

Security: escaping only changes how text is displayed. Base64 and URL encoding hide nothing: anyone can decode them. Never put passwords or private keys in encoded links.

Sources

Frequently asked questions

What does parse HTML mean in Blogger?

"Parsing" HTML for Blogger means escaping it: < becomes &lt;, > becomes &gt;, & becomes &amp; and quotes become &quot; and &#39;. The browser then shows the code as text instead of running it, which is what you need to display HTML, CSS or JavaScript examples in a post. For example <a href="/menu?item=kopi&size=L">Kopi & teh ☕</a> becomes &lt;a href=&quot;/menu?item=kopi&amp;size=L&quot;&gt;Kopi &amp; teh ☕&lt;/a&gt;.

How do I show code in a Blogger post?

Paste the code, keep HTML entities and Encode selected, tick Wrap in a code block, and copy the result. In the Blogger post editor, switch to HTML view and paste it where the code should appear. The <pre> keeps spaces and line breaks; the <code> marks it as code for screen readers and search engines.

Do I need to parse AdSense code before adding it to Blogger?

Not if you add it the recommended way: in Layout, Add a Gadget, HTML/JavaScript, paste the AdSense code unchanged. Only code pasted into the theme XML (Theme, Edit HTML) must be valid XML, where a bare & inside a script breaks saving; write it as &amp; there. Never escape the < and > of a script you want to run, or it will show as text.

What is the difference between encodeURI and encodeURIComponent?

encodeURIComponent encodes everything that has a meaning in a URL, including / ? & = and #, so use it for one value such as a search term or a parameter. encodeURI leaves those characters alone, so use it for a whole address that only needs spaces and non-ASCII letters fixed. Tick Whole URL to use encodeURI.

Is Base64 encryption?

No. Base64 only rewrites bytes with 64 safe characters (A–Z, a–z, 0–9, + and /) so binary data can travel in text such as email, JSON or data URLs. Anyone can decode it instantly, so never use it to hide passwords or links. It also makes data about 33% larger.

How do I escape a string for JavaScript or JSON?

Choose JavaScript / JSON string and Encode. Quotes become \", backslashes \\, line breaks \n and tabs \t, and </script> becomes <\/script> so it cannot end a script block early. Paste the result between double quotes. Decode does the reverse and also understands \x41, \u0041 and \u{1F600}.

Is my code uploaded?

No. Every conversion runs in your browser with JavaScript, so tokens, keys and private code never leave your device. Only your last input is kept in this browser's storage.

Advertisement