HTML Entity Encoder / Decoder
Encode special characters to HTML entities or decode entities back to plain text. Handles &, <, >, ", and '.
Frequently Asked Questions
What are HTML entities?
HTML entities are special codes that represent reserved characters in HTML. For example, & becomes &, < becomes <. They prevent the browser from misinterpreting characters as markup.
When should I encode?
Encode HTML entities whenever you display user-generated content on a web page to prevent XSS attacks. Also use encoding when you need to show reserved characters like <, >, and & as literal text.
Which characters are converted?
The encoder converts the five reserved HTML characters: & (ampersand), < (less-than), > (greater-than), " (double quote), and ' (apostrophe).