ESC
HTML Entities

Reserved Characters

Decimal Hex Named Char Description
& & & & Ampersand — must always be encoded in HTML
&#60; &#x3C; &lt; < Less-than — opens HTML tags
&#62; &#x3E; &gt; > Greater-than — closes HTML tags
&#34; &#x22; &quot; " Double quote — use inside attribute values
&#39; &#x27; &#39; ' Single quote / apostrophe — no named entity in HTML4
&#47; &#x2F; &#47; / Forward slash — safe to use unencoded in most contexts

Common Symbols

Decimal Hex Named Char Description
&#169; &#xA9; &copy; © Copyright sign
&#174; &#xAE; &reg; ® Registered trademark
&#8482; &#x2122; &trade; Trademark symbol
&#8364; &#x20AC; &euro; Euro sign
&#163; &#xA3; &pound; £ Pound sterling sign
&#165; &#xA5; &yen; ¥ Yen / yuan sign
&#167; &#xA7; &sect; § Section sign
&#176; &#xB0; &deg; ° Degree sign
&#177; &#xB1; &plusmn; ± Plus-minus sign
&#215; &#xD7; &times; × Multiplication sign
&#247; &#xF7; &divide; ÷ Division sign
&#178; &#xB2; &sup2; ² Superscript two / squared
&#179; &#xB3; &sup3; ³ Superscript three / cubed

Arrows

Decimal Hex Named Char Description
&#8592; &#x2190; &larr; Leftwards arrow
&#8594; &#x2192; &rarr; Rightwards arrow
&#8593; &#x2191; &uarr; Upwards arrow
&#8595; &#x2193; &darr; Downwards arrow
&#8596; &#x2194; &harr; Left-right arrow
&#8656; &#x21D0; &lArr; Leftwards double arrow
&#8658; &#x21D2; &rArr; Rightwards double arrow
&#8660; &#x21D4; &hArr; Left-right double arrow

Mathematical

Decimal Hex Named Char Description
&#8721; &#x2211; &sum; Summation / sigma
&#8730; &#x221A; &radic; Square root radical sign
&#8734; &#x221E; &infin; Infinity symbol
&#960; &#x3C0; &pi; π Greek letter pi
&#8776; &#x2248; &asymp; Almost equal to
&#8800; &#x2260; &ne; Not equal to
&#8804; &#x2264; &le; Less than or equal to
&#8805; &#x2265; &ge; Greater than or equal to
&#177; &#xB1; &plusmn; ± Plus or minus

Smart Quotes & Dashes

Decimal Hex Named Char Description
&#8220; &#x201C; &ldquo; Left double quotation mark (opening)
&#8221; &#x201D; &rdquo; Right double quotation mark (closing)
&#8216; &#x2018; &lsquo; Left single quotation mark (opening)
&#8217; &#x2019; &rsquo; Right single quotation mark (closing)
&#8212; &#x2014; &mdash; Em dash — used for parenthetical clauses
&#8211; &#x2013; &ndash; En dash — used in ranges (pages 5–10)

Whitespace

Decimal Hex Named Char Description
&#160; &#xA0; &nbsp; [nbsp] Non-breaking space — prevents line break
&#8194; &#x2002; &ensp; [ensp] En space — width of letter n
&#8195; &#x2003; &emsp; [emsp] Em space — width of letter m
&#8201; &#x2009; &thinsp; [thinsp] Thin space — about 1/5 of em

Frequently Asked Questions

An HTML entity is a text string that begins with & and ends with ; used to represent characters that have special meaning in HTML or cannot be easily typed. For example &lt; renders as < (less-than sign), which would otherwise be interpreted as the start of an HTML tag. Entities can be named (&amp;) or numeric decimal (&#38;) or numeric hex (&#x26;).

Always encode & as &amp;, < as &lt;, and > as &gt; in HTML content to prevent them being parsed as markup. In attribute values also encode quotes. In practice, templating engines handle this automatically with functions like htmlspecialchars() in PHP, html.escape() in Python, or {{ }} in Jinja/Twig. Manual encoding is needed when building HTML strings by concatenation.

A regular space is a word separator and browsers may collapse multiple spaces or wrap text at a space. &nbsp; (non-breaking space, U+00A0) prevents line breaks at that point and is not collapsed. Use it for units (10&nbsp;kg), abbreviations (Mr.&nbsp;Smith), or to force spacing. Do not use it for layout — use CSS padding/margin instead.

Named HTML entities are case-sensitive: &amp; works but &AMP; does not. Numeric decimal (&#38;) and hex (&#x26; or &#X26;) references are not case-sensitive for the x prefix, but the digits must be correct. When in doubt use numeric decimal references, which are universally supported across all HTML versions.