The font property is used in CSS and certain HTML elements. It is a shorthand property for setting font-style, font-variant, font-weight, font-size, line-height and font-family in a single CSS declaration.


Value Description
<style> See font-style for values.
<variant> See font-variant for values.
<weight> See font-weight for values.
<size> See font-size for values.
<line-height> See line-height for values.
<family> See font-family for values.

Any values from the properties listed above can be used in this property. A single space is required to separate each value.

HTML example:

<span style="font:bold 12pt Arial;">QWERTY</span>

That produces: QWERTY

CSS example:

h1 {
    font:bold 12pt Arial;

External Links

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.