HTML Entities Encoder/Decoder
Encode and decode HTML entities easily. Free, fast and 100% private.
Encoded result
Decoded text
Your data stays on your device. Nothing is sent to our servers.
Quick examples (click to test)
<script>alert('XSS')</script>
<p>Hello & goodbye ยฉ 2025</p>
Prix: 50โฌ โ Rรฉduction: 10%
<div>&nbsp;</div>
What is HTML entity encoding?
HTML entities are character sequences that represent special or reserved symbols in HTML. For example, the < character is encoded as < to prevent it from being interpreted as an HTML tag. This mechanism is essential for web security (XSS prevention) and for correctly displaying special characters.
Features
Ultra fast
Instant conversion in your browser, no waiting time.
100% private
Your data never leaves your device. No server uploads.
Bidirectional
Encode text to HTML entities and decode entities to text.
Multiple formats
Supports named, decimal numeric, and hexadecimal entities.
How to use?
Choose mode
Select encode (text to HTML) or decode (HTML to text).
Enter your data
Type or paste your text in the input area.
Copy the result
Copy the result or download it as a text file.
Use cases
Web security
Protect your applications against XSS attacks by encoding user input.
HTML code
Display HTML code as text in your web pages or tutorials.
Special characters
Correctly display symbols like ยฉ, โฌ, โข and other special characters.
HTML email
Encode content for newsletters and marketing emails.
Reference table
| Character | Named entity | Numeric | Description |
|---|---|---|---|
< | < | < | Less than (opening tag) |
> | > | > | Greater than (closing tag) |
& | & | & | Ampersand |
" | " | " | Double quote |
' | ' | ' | Apostrophe |
| |   | Non-breaking space |
ยฉ | © | © | Copyright |
ยฎ | ® | ® | Registered trademark |
โข | ™ | ™ | Trademark |
โฌ | € | € | Euro symbol |
Frequently asked questions
What's the difference between named and numeric entities?
Named entities use a readable name (e.g., © for ยฉ) while numeric entities use the character's Unicode code (e.g., ©). Both are equivalent but named ones are more readable.
Why is HTML character encoding important?
Encoding prevents XSS (Cross-Site Scripting) attacks by preventing malicious code injection. Without encoding, an attacker could inject JavaScript through a form.
Do all browsers support HTML entities?
Yes, HTML entities are a standard supported by all modern browsers. Common named entities like <, >, & are universally recognized.
What's the difference between < and <?
< is decimal notation (base 10) and < is hexadecimal notation (base 16). Both represent the same character (<). The hexadecimal form is sometimes preferred in programming.
Is my data sent anywhere?
No! All processing is done locally in your browser. Your data never leaves your device.