HTML Entity Encoder / Decoder
Encode special characters to HTML entities or decode HTML entities back to readable text. Free, instant, in-browser.
Common HTML Entities
FAQ
What are HTML entities?
HTML entities are special codes that represent characters which have meaning in HTML. For example, < becomes <, > becomes >, and & becomes &. This prevents browsers from interpreting them as HTML tags.
When should I encode HTML entities?
Encode when displaying user-generated content in HTML to prevent XSS attacks, when including special characters in HTML attributes, or when you need to show HTML code as text on a web page.
What is the difference between named and numeric entities?
Named entities use a human-readable name (e.g., & for &). Numeric entities use the Unicode code point (e.g., & for &). Named entities are easier to read but not all characters have named versions.
Does this tool support all Unicode characters?
Yes. Any character outside the basic ASCII range can be encoded as a numeric HTML entity (&#xxxx;). Common characters like <, >, &, ", and ' use their named entity equivalents.
More Developer Tools You May Like
JSON Formatter
Format, beautify, minify and validate JSON with syntax highlighting.
CSS Minifier
Minify CSS to reduce file size or beautify minified CSS.
Text Case Converter
Convert text between camelCase, snake_case, kebab-case, and more.
Password Generator
Generate strong, random, cryptographically secure passwords.