HTML Entity Encoder

Convert text into HTML-safe character references. Choose named entities where available, decimal references, hexadecimal references, or a minimal mode that encodes only characters with special meaning in HTML.

Choosing an Encoding Style

Minimal encoding is usually best for ordinary HTML because it changes only ampersands, angle brackets, quotation marks, and apostrophes. Decimal and hexadecimal modes encode every character and are useful for inspecting exact code points.