The CSS font properties define the font family, boldness, size, and the style of a text.

CSS Font Families

In CSS, there are two types of font family names:
  • generic family - a group of font families with a similar look (like "Serif" or "Monospace")
  • font family - a specific font family (like "Times New Roman" or "Arial")
Generic familyFont familyDescription
SerifTimes New Roman
Georgia
Serif fonts have small lines at the ends on some characters
Sans-serifArial
Verdana
"Sans" means without - these fonts do not have the lines at the ends of characters
MonospaceCourier New
Lucida Console
All monospace characters have the same width

All CSS Font Properties

PropertyDescription
fontSets all the font properties in one declaration
font-familySpecifies the font family for text
font-sizeSpecifies the font size of text
font-styleSpecifies the font style for text
font-variantSpecifies whether or not a text should be displayed in a small-caps font
font-weightSpecifies the weight of a font