Encodeur / Décodeur d'Entités HTML
Encodez les caractères spéciaux en entités HTML ou décodez-les
| Caractère | Entité (Named) | Entité (Numeric) | Nom |
|---|---|---|---|
| & | & | & | Ampersand |
| < | < | < | Less Than |
| > | > | > | Greater Than |
| " | " | " | Double Quote |
| ' | ' | ' | Apostrophe |
| ␣ | |   | Non-breaking Space |
| © | © | © | Copyright |
| ® | ® | ® | Registered |
| ™ | ™ | ™ | Trademark |
| € | € | € | Euro |
| £ | £ | £ | Pound |
| ¥ | ¥ | ¥ | Yen |
| « | « | « | Left Guillemet |
| » | » | » | Right Guillemet |
| — | — | — | Em Dash |
| – | – | – | En Dash |
| … | … | … | Ellipsis |
| · | · | · | Middle Dot |
| • | • | • | Bullet |
| × | × | × | Multiplication |
| ÷ | ÷ | ÷ | Division |
Prochaines etapes suggerees
Outils Associés
Encodeur / Decodeur Base64
Encodez rapidement du texte en Base64 ou decodez du Base64 en texte.
Encodeur / Decodeur URL
Encoder et decoder des URL
Échappement / Déséchappement de Chaîne
Échapper et désechapper des chaînes pour HTML, JSON, JavaScript, SQL et plus
Convertisseur de Base Numérique
Convertir des nombres entre binaire, octal, décimal et hexadécimal
Convertisseur d'Horodatage
Convertir entre horodatages Unix et dates lisibles
Recherche ASCII / Unicode
Rechercher et consulter les codes de caractères ASCII et Unicode
Comment utiliser
Collez ou saisissez du texte
Entrez votre texte, code ou données dans la zone de saisie.
Choisissez les options
Sélectionnez la transformation ou le format que vous souhaitez appliquer.
Copiez le résultat
Copiez la sortie dans votre presse-papiers en un clic.
Pourquoi utiliser cet outil
100 % Gratuit
Aucun coût caché, aucun niveau premium — chaque fonctionnalité est gratuite.
Aucune installation
Fonctionne entièrement dans votre navigateur. Aucun logiciel à télécharger ou installer.
Privé et sécurisé
Vos données ne quittent jamais votre appareil. Rien n'est envoyé sur un serveur.
Fonctionne sur mobile
Entièrement adaptatif — utilisez-le sur votre téléphone, tablette ou ordinateur.
HTML Entity Encoding for Secure Web Content
Key Takeaways
- HTML entity encoding converts special characters like <, >, and & into safe representations that browsers render as text, not code.
- Proper entity encoding is a primary defense against Cross-Site Scripting (XSS) attacks in web applications.
- All encoding and decoding is processed in your browser — your content never leaves your device.
HTML entity encoding is a fundamental web security practice that converts characters with special meaning in HTML into their entity equivalents. Without proper encoding, user-supplied content containing characters like < or > could be interpreted as HTML tags, leading to broken layouts or dangerous XSS vulnerabilities. Every web developer should understand when and how to apply entity encoding.
Cross-Site Scripting (XSS) remains in the OWASP Top 10 — proper output encoding prevents the majority of XSS attacks.
Security Importance
Key Concepts
Named vs. Numeric Entities
Named entities like & and < are human-readable, while numeric entities like & and < (or hex &) work for any Unicode character. Named entities cover only a subset of characters.
The Five Critical Characters
The characters < > & " ' must always be encoded in HTML content: < > & " '. These five characters form the minimum encoding set for XSS prevention.
Context-Specific Encoding
Different HTML contexts (element content, attributes, JavaScript, CSS, URLs) require different encoding strategies. Entity encoding alone is not sufficient for JavaScript or URL contexts.
Unicode Special Characters
HTML entities give access to thousands of special characters — from mathematical symbols to currency signs to arrows — without needing special fonts.
Pro Tips
Always encode output, never input — store raw data in your database and encode when rendering to HTML.
Use your framework's built-in escaping (React JSX, Angular templates, Vue {{ }}) rather than manual entity encoding.
Remember to encode inside HTML attributes too — an unencoded quote in an attribute value can break out of the attribute context.
For content that should contain real HTML (like a rich text editor), use a sanitization library like DOMPurify instead of entity encoding.
All HTML entity encoding and decoding is performed entirely in your browser. Your content is never transmitted to any external server, ensuring privacy for sensitive HTML content.