font-size: ***;

Browser
  • IE
  • Cr
  • Sf
  • Fx
  • O

The font-size property specifies the size of the font.


body {
font-size: 80%;
}

Property Value Explanation
font-size length, %, or keyword the size of the font

The font size keywords

The seven sizes :
[small] xx-small, x-small, small, medium, large, x-large, xx-large [large]

The default is "medium".

font-size: xx-small
font-size: x-small
font-size: small
font-size: medium
font-size: large
font-size: x-large
font-size: xx-large

The smaller and larger :
smaller, larger

font-size: smaller
font-size: larger

Example


<html>
<head>
<title>TAG index</title>

<style type="text/css">

p { font-size: 100%; }

#example1 { font-size: 200%; }
#example2 { font-size: 1.5em; }
#example3 { font-size: x-small; }
#example4 { font-size: larger; }

</style>

</head>
<body>

<p>The font size is <span id="example1">200%</span></p>
<p>The font size is <span id="example2">1.5em</span></p>
<p>The font size is <span id="example3">x-small</span></p>
<p>The font size is <span id="example4">larger</span></p>

</body>
</html>

Output

The font size is 200%

The font size is 1.5em

The font size is x-small

The font size is larger