HTML Symbols

Integrate mathematical notation, Greek alphabet characters, directional indicators, and specialized glyphs

Keyboard-absent symbols integrate into HTML through entity references. Markup language accommodates extensive symbol collections encompassing mathematical operators, Greek alphabet characters, directional arrows, technical notation, and additional specialized glyphs.

How to Add Symbols in HTML

To display symbols in HTML, you can use the entity name or the entity number:

Example - Displaying Symbols

<p>I will display &euro;</p>
<p>I will display &#8364;</p>

Result:

I will display €

I will display €

Note: Entity numbers have better browser support than entity names.

Mathematical Operators

HTML supports a wide range of mathematical operators that can be used in web pages.

Symbol Description Entity Name Entity Number
for all &forall; &#8704;
partial differential &part; &#8706;
there exists &exist; &#8707;
empty set &empty; &#8709;
nabla &nabla; &#8711;
element of &isin; &#8712;
not an element of &notin; &#8713;
contains as member &ni; &#8715;
product &prod; &#8719;
summation &sum; &#8721;

Example - Mathematical Operators

<p>&forall; x &isin; A</p>
<p>&sum; from i=1 to n</p>
<p>Set is &empty;</p>

Greek Letters

Greek letters are commonly used in mathematics, science, and engineering. Here are the most common Greek letters:

Uppercase Greek Letters

Symbol Name Entity Name Entity Number
Α Alpha &Alpha; &#913;
Β Beta &Beta; &#914;
Γ Gamma &Gamma; &#915;
Δ Delta &Delta; &#916;
Σ Sigma &Sigma; &#931;
Ω Omega &Omega; &#937;

Lowercase Greek Letters

Symbol Name Entity Name Entity Number
α alpha &alpha; &#945;
β beta &beta; &#946;
γ gamma &gamma; &#947;
δ delta &delta; &#948;
π pi &pi; &#960;
ω omega &omega; &#969;

Example - Greek Letters

<p>The angle &alpha; equals 45&deg;</p>
<p>&pi; &asymp; 3.14159</p>
<p>Resistance is measured in &Omega; (Ohms)</p>

Result:

The angle α equals 45°

π ≈ 3.14159

Resistance is measured in Ω (Ohms)

Arrow Symbols

Arrow symbols are useful for navigation, diagrams, and indicating direction.

Symbol Description Entity Name Entity Number
leftwards arrow &larr; &#8592;
upwards arrow &uarr; &#8593;
rightwards arrow &rarr; &#8594;
downwards arrow &darr; &#8595;
left right arrow &harr; &#8596;
leftwards double arrow &lArr; &#8656;
upwards double arrow &uArr; &#8657;
rightwards double arrow &rArr; &#8658;
downwards double arrow &dArr; &#8659;
left right double arrow &hArr; &#8660;

Example - Arrows

<p>&larr; Go back</p>
<p>Continue &rarr;</p>
<p>A &rArr; B (implies)</p>

Card Suit Symbols

Playing card suit symbols can be useful for card games and casino websites.

Symbol Description Entity Name Entity Number
spade &spades; &#9824;
club &clubs; &#9827;
heart &hearts; &#9829;
diamond &diams; &#9830;

Example - Card Suits

<p>Ace of &spades;</p>
<p>King of &hearts;</p>
<p>Queen of &diams;</p>
<p>Jack of &clubs;</p>

Miscellaneous Symbols

Symbol Description Entity Name Entity Number
square root &radic; &#8730;
infinity &infin; &#8734;
intersection &cap; &#8745;
union &cup; &#8746;
integral &int; &#8747;
approximately equal &asymp; &#8776;
identical to &equiv; &#8801;
circled plus &oplus; &#8853;

Example - Miscellaneous Symbols

<p>&radic;16 = 4</p>
<p>The limit approaches &infin;</p>
<p>&pi; &asymp; 3.14</p>

Practical Examples

Example - Mathematical Formula

<p>Quadratic Formula:</p>
<p>x = (-b &plusmn; &radic;(b<sup>2</sup> - 4ac)) / 2a</p>

Example - Greek Letters in Science

<p>The wavelength &lambda; is related to frequency by:</p>
<p>c = &lambda;&nu;</p>
<p>Where c is the speed of light.</p>

Example - Set Theory

<p>Let A = {1, 2, 3} and B = {2, 3, 4}</p>
<p>A &cap; B = {2, 3}</p>
<p>A &cup; B = {1, 2, 3, 4}</p>
<p>2 &isin; A</p>

Using Symbols with UTF-8

Important Note

To display symbols correctly, your HTML document must use UTF-8 encoding. Include this meta tag in your HTML head:

<meta charset="UTF-8">

With UTF-8 encoding, many symbols can be typed directly without using entities. However, using entities ensures better compatibility across all browsers and platforms.

Test Your Knowledge