CSS2 » Other » @font-face

Version: Level 2

Compability: IE5+  N6+

@font-face { descriptor: value; ...; };

The @font-face at-rule is used to comprehensively describe the font-face used in a document.

A list of one or more descriptor: value; components delineated (separated) by blank space are used to specify the font. You may choose from among a rather large number of such descriptor: value; components. This permits you to describe the font in detail.
A full explanation of the @font-face at-rule would be extremely lengthy and is beyond the scope of this Quick Reference. As a starting point, the Guru recommends that you refer to Chapter 15 of the W3C standard.
The syntax for an at-rule is an @ symbol, followed immediately by an unique identifier, which in turn is followed by the block which contains content that is applied on a document level. The block syntax is either:

  • all content contained between a pair of curly brackets,
  • or is all content contained between the unique identifier and a semi-colon.
There are five at-rules: @charset, @font-face, @import. @media, and @page.


@font-face { font-family: swiss721 };
Language(s): CSS2

See Also: