CSS 2.1 Properties | WebReference

CSS 2.1 Properties

CSS 2.1 Properties


Cascading Style Sheets (CSS) are used for Web page layouts. They aid in separating the document's style from its structure. They provide a simple mechanism for adding style (e.g. fonts, colors, spacing) to Web documents. Used correctly, CSS can be a powerful Web design tool.

Cascading Style Sheets were created by Håkon Wium Lie and Bert Bios. It became a World Wide Web Consortium (W3C) recommendation in December 1996. The current version is 2.1. The entire specification can be downloaded in the following formats:

HTML [zipped]   |   Plain Text [right-click/save as]   |   PDF

The CSS language is declared using a "rule." The structure of the rule is shown below:

The structure of a rule

This reference covers all the properties of the current version. Each property is listed as a link, i.e.


The link will open a popup box, but it's not an actual window. It pops right up on the page, partially hiding the page content. You will need to click the link again to close the window; the link will display a reminder. Go ahead and try the link above. (This script, Absolute Popup Box, is available over at JavaScript Source.)

Browser compatibility is also shown for each element, using the following code: IE = Microsoft Internet Explorer; NN = Netscape (includes Firefox and Mozilla); O = Opera.


CSS 2.1 Properties