Skip to content

Free HTML Encoder / Decoder

New

Convert special characters to HTML entities or decode HTML entities back to text.

Input (Plain Text/HTML)

0 characters

Output (HTML Entities)

0 characters

Common HTML Entities
<
&lt;
Less than
>
&gt;
Greater than
&
&amp;
Ampersand
"
&quot;
Double quote
'
&#39;
Single quote
&nbsp;
Non-breaking space
©
&copy;
Copyright
®
&reg;
Registered
™
&trade;
Trademark
€
&euro;
Euro

About HTML Encoding

HTML encoding is the process of converting special characters into HTML entities. This is essential for displaying characters that have special meaning in HTML (like < and >) and for preventing Cross-Site Scripting (XSS) attacks.

Security Benefits

Always encode user input before displaying it on a web page. This prevents malicious scripts from being executed. For example, if a user enters <script>alert('XSS')</script>, encoding converts it to safe text that displays literally instead of executing.

Frequently Asked Questions

Common questions about HTML Encoder.

Related free tools

What this tool does

Escape HTML-sensitive text or inspect HTML entities.

How to use it

Choose encode or decode and paste the text. Review the resulting characters before using it in markup.

Worked example

&lt; decodes to <; &amp; decodes to &.

Limitations and checks

Entity encoding is context-specific. It does not make arbitrary JavaScript, CSS or URLs safe to insert into a page.

How your data is processed

The operation runs in your browser. Copy and download actions use your device. Where Save work is offered, a local copy is stored; eligible work can sync only under your enabled account settings. See Privacy for site analytics and storage details.

Privacy and storage details · Report an incorrect result · Browse tools