Working Draft · css-fonts

CSS Fonts

27 properties, 10 at-rules, 1 function, 2 types defined by this specification, 31 of them known to at least one browser (the others are badged Not in any browser yet).

Each feature in detail

font

Property Baseline: widely availablesince January 2018

MDN The font CSS shorthand property sets all the different properties of an element's font. Alternatively, it sets an element's font to a system font.

Live preview Example from MDN
@font-face {
  font-family: "Fira Sans";
  src:
    local("FiraSans-Regular"),
    url("https://developer.mozilla.org/shared-assets/fonts/FiraSans-Regular.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "Fira Sans";
  src:
    local("FiraSans-Italic"),
    url("https://developer.mozilla.org/shared-assets/fonts/FiraSans-Italic.woff2") format("woff2");
  font-weight: normal;
  font-style: italic;
}

section {
  margin-top: 10px;
  font-size: 1.1em;
}

Syntax

[ [ <'font-style'> || <font-variant-css2> || <'font-weight'> || <font-width-css3> ]? <'font-size'> [ / <'line-height'> ]? <'font-family'># ] | <system-font-family-name>

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
see individual properties
Applies to
all elements and text
Inherited
yes
Percentages
see individual properties
Computed value
see individual properties
Canonical order
per grammar
Animation type
see individual properties
Longhands
font-style, font-variant, font-weight, font-stretch, font-size, line-height, font-family

Browser support

First browser version supporting font
Chrome 1
Edge 12
Firefox 1
Safari 1
Chrome Android 18
Safari iOS 1

First version with support, from MDN browser-compat-data.

font-family

Property Baseline: widely availablesince May 2025

MDN The @font-palette-values descriptor font-family is used to specify which font-family palette values are to be applied to. This need to match exactly the values used when setting the CSS font-family.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Bungee+Spice";
@font-palette-values --bungee-extra-spicy {
  font-family: "Bungee Spice";
  override-colors:
    0 darkred,
    1 red;
}

h2 {
  font-family: "Bungee Spice", fantasy;
}

h2.extra-spicy {
  font-palette: --bungee-extra-spicy;
}

Syntax

[ <font-family-name> | <generic-font-family> ]#

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
depends on user agent
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
list, each item a string and/or <generic-font-family> keywords
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-family
Chrome 101
Edge 101
Firefox 107
Safari 15.4
Chrome Android 101
Safari iOS 15.4

First version with support, from MDN browser-compat-data.

font-feature-settings

Property Baseline: widely availablesince September 2018

MDN The font-feature-settings CSS descriptor allows you to define the initial settings to use for the font defined by the @font-face at-rule. You can further use this descriptor to control typographic font features such as ligatures, small caps, and swashes, for the font defined by @font-face. The values for this descriptor are the same as the font-feature-settings property, except for the global keyword values.

Live preview Example from MDN
@font-face {
  font-family: "MonteCarlo";
  src: url("https://developer.mozilla.org/shared-assets/fonts/monte-carlo/monte-carlo-regular.woff2");
}
@font-face {
  font-family: "MonteCarlo2";
  src: url("https://developer.mozilla.org/shared-assets/fonts/monte-carlo/monte-carlo-regular.woff2");
  font-feature-settings: "swsh" 1;
}
p {
  font-size: 3rem;
  margin: 0.7rem 3rem;
}
.swash-off {
  font-family: "MonteCarlo", cursive;
}
.swash-on {
  font-family: "MonteCarlo2", cursive;
}

Syntax

normal | <feature-tag-value>#

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-feature-settings
Chrome 140
Edge 140
Firefox 34
Safari 10
Chrome Android 140
Safari iOS 10

First version with support, from MDN browser-compat-data.

font-kerning

Property Baseline: widely availablesince July 2022

MDN The font-kerning CSS property sets the use of the kerning information stored in a font.

Live preview Example from MDN
section {
  font-family: serif;
}

Syntax

auto | normal | none

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
auto
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-kerning
Chrome 33
Edge 79
Firefox 32
Safari 9
Chrome Android 33
Safari iOS 9

First version with support, from MDN browser-compat-data.

font-language-override

Property Limited availability Modern CSS: font-language-override

MDN The font-language-override CSS property controls the use of language-specific glyphs in a typeface.

Live preview Example from MDN
p.para1 {
  font-language-override: normal;
}

p.para2 {
  font-language-override: "DAN";
}

Syntax

normal | <string>

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
N/A
Computed value
specified string or the keyword none
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-language-override
Chrome 143
Edge 143
Firefox 34
Safari No
Chrome Android 143
Safari iOS No

First version with support, from MDN browser-compat-data.

font-optical-sizing

Property Baseline: widely availablesince September 2022

MDN The font-optical-sizing CSS property sets whether text rendering is optimized for viewing at different sizes.

Live preview Example from MDN
@font-face {
  src: url("https://developer.mozilla.org/shared-assets/fonts/variable-fonts/AmstelvarAlpha-VF.woff2");
  font-family: "Amstelvar";
  font-style: normal;
}

#example-element {
  font-family: "Amstelvar", serif;
  text-align: left;
}

#example-element h2 {
  font-size: 36px;
}

#example-element p {
  font-size: 12px;
}

Syntax

auto | none

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
auto
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-optical-sizing
Chrome 79
Edge 17
Firefox 62
Safari 13.1
Chrome Android 79
Safari iOS 13.4

First version with support, from MDN browser-compat-data.

font-palette

Property Baseline: widely availablesince May 2025 Modern CSS: font-palette animation

MDN The font-palette CSS property allows specifying one of the many palettes contained in a color font that a user agent may use for the font. Users can also override the values in a palette or create a new palette by using the @font-palette-values at-rule.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Nabla&display=swap";

@font-palette-values --blue-nabla {
  font-family: "Nabla";
  base-palette: 2; /* this is Nabla's blue palette */
}

@font-palette-values --grey-nabla {
  font-family: "Nabla";
  base-palette: 3; /* this is Nabla's grey palette */
}

@keyframes animate-palette {
  from {
    font-palette: --grey-nabla;
  }

  to {
    font-palette: --blue-nabla;
  }
}

p {
  font-family: "Nabla", fantasy;
  font-size: 5rem;
  margin: 0;
  text-align: center;
  animation: animate-palette 4s infinite alternate linear;
}

Syntax

normal | light | dark | <palette-identifier> | <palette-mix()>

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
N/a
Computed value
specified keyword, identifier or <palette-mix()> function. <palette-mix()> must be simplified to a single keyword or identifier if resulting palette is equivalent.
Canonical order
per grammar
Animation type
by computed value

Browser support

First browser version supporting font-palette
Chrome 101
Edge 101
Firefox 107
Safari 15.4
Chrome Android 101
Safari iOS 15.4

First version with support, from MDN browser-compat-data.

font-size

Property Baseline: widely availablesince January 2018 Modern CSS: MathML

MDN The font-size CSS property sets the size of the font. Changing the font size also updates the sizes of the font size-relative <length> units, such as em, ex, and so forth.

Live preview Example from MDN
<section id="default-example">
  <p id="example-element">
    London. Michaelmas term lately over, and the Lord Chancellor sitting in
    Lincoln's Inn Hall. Implacable November weather. As much mud in the streets
    as if the waters had but newly retired from the face of the earth, and it
    would not be wonderful to meet a Megalosaurus, forty feet long or so,
    waddling like an elephantine lizard up Holborn Hill.
  </p>
</section>

Syntax

<absolute-size> | <relative-size> | <length-percentage [0,∞]> | math

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
medium
Applies to
all elements and text
Inherited
yes
Percentages
refer to parent element’s font size
Computed value
an absolute length
Canonical order
per grammar
Animation type
by computed value type

Browser support

First browser version supporting font-size
Chrome 1
Edge 12
Firefox 1
Safari 1
Chrome Android 18
Safari iOS 1

First version with support, from MDN browser-compat-data.

font-size-adjust

Property Baseline: newly availablesince July 2024 Modern CSS: font-size-adjust

MDN The font-size-adjust CSS property adjusts the size of a font to match a chosen font metric, such as the height of lowercase letters, to a specified proportion of the font-size. This property is intended for adjusting fallback fonts to have similar metrics as the first-choice font.

Live preview Example from MDN
.times {
  font-family: "Times", serif;
  font-size: 14px;
}

.verdana {
  font-family: "Verdana", sans-serif;
  font-size: 14px;
}

.adj-times-ex-height {
  font-size-adjust: 0.545;
}

.adj-times-cap-height {
  font-size-adjust: cap-height 0.73;
}

Syntax

none | [ ex-height | cap-height | ch-width | ic-width | ic-height ]? [ from-font | <number [0,∞]> ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
none
Applies to
all elements and text
Inherited
yes
Percentages
N/A
Computed value
the keyword none, or a pair of a metric keyword and a <number>
Canonical order
per grammar
Animation type
discrete if the keywords differ, otherwise by computed value type

Browser support

First browser version supporting font-size-adjust
Chrome 127
Edge 127
Firefox 3
Safari 16.4
Chrome Android 127
Safari iOS 16.4

First version with support, from MDN browser-compat-data.

font-stretch

Property Baseline: widely availablesince July 2022

MDN The font-stretch CSS descriptor allows authors to specify a normal, condensed, or expanded face for the fonts specified in the @font-face at-rule.

Live preview Example from MDN
@font-face {
  font-family: "League Mono Ultra Condensed";
  src: url("https://developer.mozilla.org/shared-assets/fonts/LeagueMono-VF.ttf") format("truetype");
  font-stretch: ultra-condensed; /* same as 50% */
}

@font-face {
  font-family: "League Mono Normal";
  src: url("https://developer.mozilla.org/shared-assets/fonts/LeagueMono-VF.ttf") format("truetype");
  font-stretch: 100%; /* same as normal */
}

@font-face {
  font-family: "League Mono Ultra Expanded";
  src: url("https://developer.mozilla.org/shared-assets/fonts/LeagueMono-VF.ttf") format("truetype");
  font-stretch: ultra-expanded; /* same as 200% */
}

p:nth-child(1) {
  font-family: "League Mono Ultra Condensed", sans-serif;
}

p:nth-child(2) {
  font-family: "League Mono Normal", sans-serif;
}

p:nth-child(3) {
  font-family: "League Mono Ultra Expanded", sans-serif;
}

Syntax

normal | <percentage [0,∞]> | ultra-condensed | extra-condensed | condensed | semi-condensed | semi-expanded | expanded | extra-expanded | ultra-expanded

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Browser support

First browser version supporting font-stretch
Chrome 62
Edge 17
Firefox 62
Safari 10.1
Chrome Android 62
Safari iOS 10.3

First version with support, from MDN browser-compat-data.

font-style

Property Baseline: widely availablesince January 2018

MDN The font-style CSS descriptor allows authors to specify font styles for the fonts specified in the @font-face at-rule.

Syntax

normal | italic | left | right | oblique <angle [-90deg,90deg]>?

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
the keyword specified, plus angle in degrees if specified
Canonical order
per grammar
Animation type
by computed value type; normal animates as oblique 0deg

Browser support

First browser version supporting font-style
Chrome 4
Edge 12
Firefox 3.5
Safari 3.1
Chrome Android 18
Safari iOS 2

First version with support, from MDN browser-compat-data.

font-synthesis

Property Baseline: widely availablesince July 2024

MDN The font-synthesis CSS shorthand property lets you specify whether or not the browser may synthesize the bold, italic, small-caps, and/or subscript and superscript typefaces when they are missing in the specified font-family.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Oxygen&display=swap";
@import "https://fonts.googleapis.com/css2?family=Ma+Shan+Zheng&display=swap";

.english {
  font-size: 1.2em;
  font-family: "Oxygen", sans-serif;
}

.chinese {
  font-size: 1.2em;
  font-family: "Ma Shan Zheng", cursive;
}

.bold {
  font-weight: bold;
}

.italic {
  font-style: italic;
}

.small-caps {
  font-variant: small-caps;
}

.sub {
  font-variant: sub;
}

.sup {
  font-variant: super;
}

Syntax

none | [ weight || style || small-caps || position]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
weight style small-caps position
Applies to
all elements and text
Inherited
yes
Percentages
N/A
Computed value
specified keyword(s)
Canonical order
per grammar
Animation type
discrete
Longhands
font-synthesis-weight, font-synthesis-style, font-synthesis-small-caps

Browser support

First browser version supporting font-synthesis
Chrome 97
Edge 97
Firefox 34
Safari 9
Chrome Android 97
Safari iOS 9

First version with support, from MDN browser-compat-data.

font-synthesis-position

Property Limited availability Experimental Modern CSS: font-synthesis-position

MDN The font-synthesis-position CSS property lets you specify whether or not a browser may synthesize the subscript and superscript "position" typefaces when they are missing in a font family, while using font-variant-position to set the positions.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Montserrat&display=swap";

* {
  font-family: "Montserrat", sans-serif;
}
.super {
  font-variant-position: super;
}
.sub {
  font-variant-position: sub;
}
.no-syn {
  font-synthesis-position: none;
}

Syntax

auto | none

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
auto
Applies to
all elements and text
Inherited
yes
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-synthesis-position
Chrome No
Edge No
Firefox 118
Safari No
Chrome Android No
Safari iOS No

First version with support, from MDN browser-compat-data.

font-synthesis-small-caps

Property Baseline: widely availablesince September 2025 Modern CSS: font-synthesis-small-caps

MDN The font-synthesis-small-caps CSS property lets you specify whether or not the browser may synthesize small-caps typeface when it is missing in a font family. Small-caps glyphs typically use the form of uppercase letters but are reduced to the size of lowercase letters.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Montserrat&display=swap";

.english {
  font-family: "Montserrat", sans-serif;
}
.small-caps {
  font-variant: small-caps;
}
.no-syn {
  font-synthesis-small-caps: none;
}

Syntax

auto | none

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
auto
Applies to
all elements and text
Inherited
yes
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-synthesis-small-caps
Chrome 97
Edge 97
Firefox 111
Safari 16.4
Chrome Android 97
Safari iOS 16.4

First version with support, from MDN browser-compat-data.

font-synthesis-style

Property Baseline: widely availablesince September 2025 Modern CSS: font-synthesis-style

MDN The font-synthesis-style CSS property lets you specify whether or not the browser may synthesize the oblique typeface when it is missing in a font family.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Montserrat&display=swap";

.english {
  font-family: "Montserrat", sans-serif;
}

.no-syn {
  font-synthesis-style: none;
}

Syntax

auto | none | oblique-only

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
auto
Applies to
all elements and text
Inherited
yes
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-synthesis-style
Chrome 97
Edge 97
Firefox 111
Safari 16.4
Chrome Android 97
Safari iOS 16.4

First version with support, from MDN browser-compat-data.

font-synthesis-weight

Property Baseline: widely availablesince September 2025 Modern CSS: font-synthesis-weight

MDN The font-synthesis-weight CSS property lets you specify whether or not the browser may synthesize the bold typeface when it is missing in a font family.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Montserrat&display=swap";

.english {
  font-family: "Montserrat", sans-serif;
}
.no-syn {
  font-synthesis-weight: none;
}

Syntax

auto | none

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
auto
Applies to
all elements and text
Inherited
yes
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-synthesis-weight
Chrome 97
Edge 97
Firefox 111
Safari 16.4
Chrome Android 97
Safari iOS 16.4

First version with support, from MDN browser-compat-data.

font-variant

Property Baseline: widely availablesince January 2018

MDN The font-variant CSS shorthand property allows you to set all the font variants for a font.

Live preview Example from MDN
@font-face {
  font-family: "Fira Sans";
  src:
    local("FiraSans-Regular"),
    url("https://developer.mozilla.org/shared-assets/fonts/FiraSans-Regular.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
}

section {
  font-family: "Fira Sans", sans-serif;
  margin-top: 10px;
  font-size: 1.5em;
}

#example-element table {
  margin-left: auto;
  margin-right: auto;
}

.tabular {
  border: 1px solid;
}

Syntax

normal | none | [ [ <common-lig-values> || <discretionary-lig-values> || <historical-lig-values> || <contextual-alt-values> ] || [ small-caps | all-small-caps | petite-caps | all-petite-caps | unicase | titling-caps ] || [ stylistic(<font-feature-value-name>) || historical-forms || styleset(<font-feature-value-name>#) || character-variant(<font-feature-value-name>#) || swash(<font-feature-value-name>) || ornaments(<font-feature-value-name>) || annotation(<font-feature-value-name>) ] || [ <numeric-figure-values> || <numeric-spacing-values> || <numeric-fraction-values> || ordinal || slashed-zero ] || [ <east-asian-variant-values> || <east-asian-width-values> || ruby ] || [ sub | super ] || [ text | emoji | unicode ] ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete
Longhands
font-variant-ligatures, font-variant-caps, font-variant-alternates, font-variant-numeric, font-variant-east-asian, font-variant-position, font-variant-emoji

Browser support

First browser version supporting font-variant
Chrome 1
Edge 12
Firefox 1
Safari 1
Chrome Android 18
Safari iOS 1

First version with support, from MDN browser-compat-data.

font-variant-alternates

Property Baseline: widely availablesince September 2025 Modern CSS: font-variant-alternates

MDN The font-variant-alternates CSS property controls the usage of alternate glyphs. These alternate glyphs may be referenced by alternative names defined in @font-feature-values.

Live preview Example from MDN
@font-face {
  font-family: "MonteCarlo";
  src: url("https://developer.mozilla.org/shared-assets/fonts/monte-carlo/monte-carlo-regular.woff2");
}

@font-feature-values "MonteCarlo" {
  @swash {
    fancy: 1;
  }
}

p {
  font-family: "MonteCarlo", cursive;
  font-size: 3rem;
  margin: 0.7rem 3rem;
}

.variant {
  font-variant-alternates: swash(fancy);
}

Syntax

normal | [ stylistic(<font-feature-value-name>) || historical-forms || styleset(<font-feature-value-name>#) || character-variant(<font-feature-value-name>#) || swash(<font-feature-value-name>) || ornaments(<font-feature-value-name>) || annotation(<font-feature-value-name>) ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-variant-alternates
Chrome 111
Edge 111
Firefox 34
Safari 9.1
Chrome Android 111
Safari iOS 9.3

First version with support, from MDN browser-compat-data.

font-variant-caps

Property Baseline: widely availablesince July 2022

MDN The font-variant-caps CSS property controls the use of alternate glyphs used for small or petite capitals or for titling.

Live preview Example from MDN
@font-face {
  font-family: "Fira Sans";
  src:
    local("FiraSans-Regular"),
    url("https://developer.mozilla.org/shared-assets/fonts/FiraSans-Regular.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
}

section {
  font-family: "Fira Sans", sans-serif;
  margin-top: 10px;
  font-size: 1.5em;
}

Syntax

normal | small-caps | all-small-caps | petite-caps | all-petite-caps | unicase | titling-caps

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-variant-caps
Chrome 52
Edge 79
Firefox 34
Safari 9.1
Chrome Android 52
Safari iOS 9.3

First version with support, from MDN browser-compat-data.

font-variant-east-asian

Property Baseline: widely availablesince July 2022

MDN The font-variant-east-asian CSS property controls the use of alternate glyphs for East Asian scripts, like Japanese and Chinese.

Live preview Example from MDN
section {
  font-family:
    "YuGothic Medium", "YuGothic", "Yu Gothic Medium", "Yu Gothic", sans-serif;
  margin-top: 10px;
  font-size: 1.5em;
}

Syntax

normal | [ <east-asian-variant-values> || <east-asian-width-values> || ruby ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-variant-east-asian
Chrome 63
Edge 79
Firefox 34
Safari 9.1
Chrome Android 63
Safari iOS 9.3

First version with support, from MDN browser-compat-data.

font-variant-emoji

Property Limited availability Modern CSS: font-variant-emoji

MDN The font-variant-emoji CSS property specifies the default presentation style for displaying emojis.

Live preview Example from MDN
@supports (font-variant-emoji: emoji) {
  .no-support {
    display: none;
  }
  .emojis {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    font-family:
      "Noto Color Emoji", "Segoe UI Emoji", "Apple Color Emoji", sans-serif;
  }
  .emoji > div {
    font-size: 2rem;
  }
}

@supports not (font-variant-emoji: emoji) {
  .emojis {
    display: none;
  }
}

.text-presentation {
  font-variant-emoji: text;
}

.emoji-presentation {
  font-variant-emoji: emoji;
}

Syntax

normal | text | emoji | unicode

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
N/a
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-variant-emoji
Chrome 131
Edge 131
Firefox 141
Safari Preview
Chrome Android 131
Safari iOS 17.5 (flag)

First version with support, from MDN browser-compat-data.

font-variant-ligatures

Property Baseline: widely availablesince July 2022

MDN The font-variant-ligatures CSS property controls which ligatures and contextual forms are used in the textual content of the elements it applies to. This leads to more harmonized forms in the resulting text.

Live preview Example from MDN
@font-face {
  font-family: "Fira Sans";
  src:
    local("FiraSans-Regular"),
    url("https://developer.mozilla.org/shared-assets/fonts/FiraSans-Regular.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
}

section {
  font-family: "Fira Sans", sans-serif;
  margin-top: 10px;
  font-size: 1.5em;
}

Syntax

normal | none | [ <common-lig-values> || <discretionary-lig-values> || <historical-lig-values> || <contextual-alt-values> ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-variant-ligatures
Chrome 34
Edge 79
Firefox 34
Safari 9.1
Chrome Android 34
Safari iOS 9.3

First version with support, from MDN browser-compat-data.

font-variant-numeric

Property Baseline: widely availablesince July 2022

MDN The font-variant-numeric CSS property controls the usage of alternate glyphs for numbers, fractions, and ordinal markers.

Live preview Example from MDN
@font-face {
  font-family: "Source Sans Pro";
  src:
    local("SourceSansPro-Regular"),
    url("https://developer.mozilla.org/shared-assets/fonts/SourceSansPro-Regular.otf") format("opentype");
  font-weight: normal;
  font-style: normal;
}

section {
  font-family: "Source Sans Pro", sans-serif;
  margin-top: 10px;
  font-size: 1.5em;
}

#example-element table {
  margin-left: auto;
  margin-right: auto;
}

.tabular {
  border: 1px solid;
}

Syntax

normal | [ <numeric-figure-values> || <numeric-spacing-values> || <numeric-fraction-values> || ordinal || slashed-zero ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-variant-numeric
Chrome 52
Edge 79
Firefox 34
Safari 9.1
Chrome Android 52
Safari iOS 9.3

First version with support, from MDN browser-compat-data.

font-variant-position

Property Limited availability Modern CSS: font-variant-position

MDN The font-variant-position CSS property controls the use of alternate, smaller glyphs that are positioned as superscript or subscript.

Live preview Example from MDN
p {
  display: inline;
}

.normal {
  font-variant-position: normal;
}

.super {
  font-variant-position: super;
}

.sub {
  font-variant-position: sub;
}

Syntax

normal | sub | super

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
as specified
Canonical order
per grammar
Animation type
discrete

Browser support

First browser version supporting font-variant-position
Chrome 117
Edge 117
Firefox 34
Safari 9.1
Chrome Android 117
Safari iOS 9.3

First version with support, from MDN browser-compat-data.

font-variation-settings

Property Baseline: widely availablesince March 2021

MDN The font-variation-settings CSS descriptor allows authors to specify low-level OpenType or TrueType font variations in the @font-face at-rule. The values for this descriptor are the same as the font-variation-settings property, except for the global keyword values.

Syntax

normal | [ <opentype-tag> <number> ]#

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
the keyword normal or a list, each item a string paired with a number
Canonical order
per grammar
Animation type
see prose

Browser support

First browser version supporting font-variation-settings
Chrome 140
Edge 140
Firefox 62
Safari No
Chrome Android 140
Safari iOS No

First version with support, from MDN browser-compat-data.

font-weight

Property Baseline: widely availablesince January 2018

MDN The font-weight CSS @font-face descriptor enables authors to specify a single font weight, or a range of font weights, for the font specified in a @font-face at-rule. This is then used by the browser to select the appropriate font when a CSS rule sets a desired font weight.

Live preview Example from MDN
@font-face {
  font-family: "Fira Sans";
  font-weight: normal;
  src: url("https://mdn.github.io/shared-assets/fonts/FiraSans-Regular.woff2");
}

@font-face {
  font-family: "Fira Sans";
  font-weight: bold;
  src: url("https://mdn.github.io/shared-assets/fonts/FiraSans-Bold.woff2");
}

body {
  font-family: "Fira Sans", serif;
  font-size: 2rem;
}

p.one {
  font-weight: normal;
}

p.two {
  font-weight: bold;
}

Syntax

<font-weight-absolute> | bolder | lighter

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
n/a
Computed value
a number, see below
Canonical order
per grammar
Animation type
by computed value type

Browser support

First browser version supporting font-weight
Chrome 4
Edge 12
Firefox 3.5
Safari 3.1
Chrome Android 18
Safari iOS 2

First version with support, from MDN browser-compat-data.

font-width

Property Limited availability Experimental Modern CSS: font-width

MDN The font-width CSS descriptor allows authors to specify a normal, condensed, or expanded face for the fonts specified in the @font-face at-rule.

Live preview Example from MDN
@font-face {
  font-family: "League Mono Ultra Condensed";
  src: url("https://developer.mozilla.org/shared-assets/fonts/LeagueMono-VF.ttf") format("truetype");
  font-width: ultra-condensed; /* same as 50% */
}

@font-face {
  font-family: "League Mono Normal";
  src: url("https://developer.mozilla.org/shared-assets/fonts/LeagueMono-VF.ttf") format("truetype");
  font-width: 100%; /* same as normal */
}

@font-face {
  font-family: "League Mono Ultra Expanded";
  src: url("https://developer.mozilla.org/shared-assets/fonts/LeagueMono-VF.ttf") format("truetype");
  font-width: ultra-expanded; /* same as 200% */
}

p:nth-child(1) {
  font-family: "League Mono Ultra Condensed", sans-serif;
}

p:nth-child(2) {
  font-family: "League Mono Normal", sans-serif;
}

p:nth-child(3) {
  font-family: "League Mono Ultra Expanded", sans-serif;
}

Syntax

normal | <percentage [0,∞]> | ultra-condensed | extra-condensed | condensed | semi-condensed | semi-expanded | expanded | extra-expanded | ultra-expanded

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Definition

Initial
normal
Applies to
all elements and text
Inherited
yes
Percentages
Not resolved
Computed value
a percentage, see below
Canonical order
per grammar
Animation type
by computed value type

Browser support

First browser version supporting font-width
Chrome No
Edge No
Firefox No
Safari 18.4
Chrome Android No
Safari iOS 18.4

First version with support, from MDN browser-compat-data.

@annotation

At-rule Not in any browser yet

No prose in the spec's definition and no MDN page yet: the spec link below is the only description.

Syntax

/* for @font-feature-values */
@annotation { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Defined for

@font-feature-values

This feature only appears in the context of these properties, functions or types.

@character-variant

At-rule Not in any browser yet

No prose in the spec's definition and no MDN page yet: the spec link below is the only description.

Syntax

/* for @font-feature-values */
@character-variant { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Defined for

@font-feature-values

This feature only appears in the context of these properties, functions or types.

@font-face

At-rule Baseline: widely availablesince March 2019 Modern CSS: font-size-adjust

MDN The @font-face CSS at-rule specifies a custom font with which to display text; the font can be loaded from either a remote server or a locally-installed font on the user's own computer.

Live preview Example from MDN
@font-face {
  font-family: "Bitstream Vera Serif Bold";
  src: url("https://mdn.github.io/shared-assets/fonts/FiraSans-Regular.woff2");
}

body {
  font-family: "Bitstream Vera Serif Bold", serif;
}

Syntax

@font-face { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Browser support

First browser version supporting @font-face
Chrome 1
Edge 12
Firefox 3.5
Safari 3.1
Chrome Android 18
Safari iOS 2

First version with support, from MDN browser-compat-data.

Descriptors

ascent-override
[ normal | <percentage [0,∞]> ]{1,2} Initial: normal
descent-override
[ normal | <percentage [0,∞]> ]{1,2} Initial: normal
font-display
auto | block | swap | fallback | optional Initial: auto
font-family
<font-family-name> Initial: N/A
font-feature-settings
normal | <feature-tag-value># Initial: normal
font-language-override
normal | <string> Initial: normal
font-named-instance
auto | <string> Initial: auto
font-size
auto | [<number>]{1,2} Initial: auto
font-style
auto | normal | italic | left | right | oblique [ <angle [-90deg,90deg]>{1,2} ]? Initial: auto
font-variation-settings
normal | [ <string> <number>]# Initial: normal
font-weight
auto | <font-weight-absolute>{1,2} Initial: auto
font-width
auto | <'font-width'>{1,2} Initial: auto
line-gap-override
[ normal | <percentage [0,∞]> ]{1,2} Initial: normal
size-adjust
<percentage [0,∞]> Initial: 100%
src
<font-src-list> Initial: N/A
subscript-position-override
[ normal | from-font | <percentage> ]{1,2} Initial: normal
subscript-size-override
[ normal | from-font | <percentage [0,∞]> ]{1,2} Initial: normal
superscript-position-override
[ normal | from-font | <percentage> ]{1,2} Initial: normal
superscript-size-override
[ normal | from-font | <percentage [0,∞]> ]{1,2} Initial: normal
unicode-range
<unicode-range-token># Initial: U+0-10FFFF

@font-feature-values

At-rule Baseline: widely availablesince September 2025 Modern CSS: font-variant-alternates

MDN The @font-feature-values CSS at-rule lets you use a common name in the font-variant-alternates property for features activated differently in OpenType. This can help simplify your CSS when using multiple fonts.

Syntax

@font-feature-values <font-family-name># { <declaration-rule-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Browser support

First browser version supporting @font-feature-values
Chrome 111
Edge 111
Firefox 34
Safari 9.1
Chrome Android 111
Safari iOS 9.3

First version with support, from MDN browser-compat-data.

Descriptors

font-display
auto | block | swap | fallback | optional Initial: auto

@font-palette-values

At-rule Baseline: widely availablesince May 2025

Spec The @font-palette-values rule defines a color palette and associates that color palette with a specific font. This allows a web author to select arbitrary <color>s to use inside a color font rather than being limited to the preexisting palettes inside font files.

MDN The @font-palette-values CSS at-rule allows you to customize the default values of font-palette created by the font-maker.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Bungee+Spice";
p {
  font-family: "Bungee Spice", fantasy;
  font-size: 2rem;
}
@font-palette-values --Alternate {
  font-family: "Bungee Spice";
  override-colors:
    0 #00ffbb,
    1 #007744;
}
.alternate {
  font-palette: --Alternate;
}

Syntax

@font-palette-values <dashed-ident> { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Browser support

First browser version supporting @font-palette-values
Chrome 101
Edge 101
Firefox 107
Safari 15.4
Chrome Android 101
Safari iOS 15.4

First version with support, from MDN browser-compat-data.

Descriptors

base-palette
light | dark | <integer [0,∞]> Initial: N/A
font-family
<font-family-name># Initial: N/A
override-colors
[ <integer [0,∞]> <color> ]# Initial: N/A

@historical-forms

At-rule Not in any browser yet

No prose in the spec's definition and no MDN page yet: the spec link below is the only description.

Syntax

/* for @font-feature-values */
@historical-forms { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Defined for

@font-feature-values

This feature only appears in the context of these properties, functions or types.

@ornaments

At-rule Not in any browser yet

No prose in the spec's definition and no MDN page yet: the spec link below is the only description.

Syntax

/* for @font-feature-values */
@ornaments { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Defined for

@font-feature-values

This feature only appears in the context of these properties, functions or types.

@styleset

At-rule Not in any browser yet

No prose in the spec's definition and no MDN page yet: the spec link below is the only description.

Syntax

/* for @font-feature-values */
@styleset { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Defined for

@font-feature-values

This feature only appears in the context of these properties, functions or types.

@stylistic

At-rule Not in any browser yet

No prose in the spec's definition and no MDN page yet: the spec link below is the only description.

Syntax

/* for @font-feature-values */
@stylistic { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Defined for

@font-feature-values

This feature only appears in the context of these properties, functions or types.

@swash

At-rule Not in any browser yet

No prose in the spec's definition and no MDN page yet: the spec link below is the only description.

Syntax

/* for @font-feature-values */
@swash { <declaration-list> }

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Defined for

@font-feature-values

This feature only appears in the context of these properties, functions or types.

palette-mix()

Function Limited availability Experimental Modern CSS: font-palette animation

Spec With the palette-mix() function defined as follows:

MDN The palette-mix() CSS function can be used to create a new font-palette value by blending together two font-palette values by specified percentages and color interpolation methods.

Live preview Example from MDN
@import "https://fonts.googleapis.com/css2?family=Nabla&display=swap";

@font-palette-values --blue-nabla {
  font-family: "Nabla";
  base-palette: 2; /* this is Nabla's blue palette */
}

@font-palette-values --yellow-nabla {
  font-family: "Nabla";
  base-palette: 7; /* this is Nabla's yellow palette */
}

p {
  font-family: "Nabla", fantasy;
  font-size: 4rem;
  text-align: center;
  margin: 0;
}

.yellowPalette {
  font-palette: --yellow-nabla;
}

.bluePalette {
  font-palette: --blue-nabla;
}

.mixedPalette {
  font-palette: palette-mix(in lch, --blue-nabla 55%, --yellow-nabla 45%);
}

Syntax

palette-mix( <color-interpolation-method>? , [ <'font-palette'> && <percentage [0,100]>? ]# )

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

Browser support

First browser version supporting palette-mix()
Chrome 121
Edge 121
Firefox No
Safari No
Chrome Android 121
Safari iOS No

First version with support, from MDN browser-compat-data.

<absolute-size>

Type Not in any browser yet

MDN The <absolute-size> CSS data type describes the absolute size keywords. This data type is used in the font shorthand and font-size properties.

Live preview Example from MDN
li {
  margin-bottom: 0.3em;
}
.xx-small {
  font-size: xx-small;
}
.x-small {
  font-size: x-small;
}
.small {
  font-size: small;
}
.medium {
  font-size: medium;
}
.large {
  font-size: large;
}
.x-large {
  font-size: x-large;
}
.xx-large {
  font-size: xx-large;
}
.xxx-large {
  font-size: xxx-large;
}

Syntax

[ xx-small | x-small | small | medium | large | x-large | xx-large | xxx-large ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.

<relative-size>

Type Not in any browser yet

MDN The <relative-size> CSS data type describes relative size keywords. The <relative-size> keywords define a size relative to the computed size of the parent element. This data type is used in the font shorthand and font-size properties.

Live preview Example from MDN
li {
  margin-bottom: 0.3em;
}
.smaller {
  font-size: smaller;
}
.larger {
  font-size: larger;
}

Syntax

[ larger | smaller ]

Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.