CSS font-variation-settings Property
Description
The font-variation-settings property gives authors low-level access to the individual design axes exposed by a variable font, letting you tune a typeface’s shapes in ways that higher-level font properties don’t always expose. Instead of selecting a preset like “bold” or “condensed,” it targets the font’s internal axes directly so you can adjust weight, width, optical size or other designer-defined axes with fine granularity. This makes it possible to achieve subtle typographic refinements — for example, balancing stroke contrast, optical correction at different sizes, or intermediate styles that don’t exist as separate static font files.
Because it operates at the axis level, font-variation-settings is most useful when you actually use a variable font family (declared with font-family) that exposes the desired axes. It sits alongside the higher-level font properties: the browser will also consider rules like font-weight that map to common axes, but by specifying axis values directly you can achieve results that the higher-level keywords cannot express. In practice you use the property when you need absolute control over a design axis — for instance in design systems or when fine-tuning typographic rhythm across responsive breakpoints — while still relying on regular font selection and fallback behavior through your font stack.
Practical considerations include animation, accessibility, and robustness. Many axes are animatable, so designers can create smooth transitions between styles, but animating complex shape changes can have performance implications on less powerful devices. Not all fonts expose the same axes, so authoring defensively (with sensible fallbacks in the font stack and not relying on a single axis to convey critical information) is important. For feature-level typographic control that focuses on OpenType substitutions and alternates rather than continuous axes, authors typically use font-feature-settings in tandem with variable axes to combine discrete feature toggles with continuous shape control. Overall, font-variation-settings is a powerful tool for nuanced typography when used with variable fonts and a clear design intent.
Definition
- Initial value
- normal
- Applies to
- all elements. It also applies to ::first-letter and ::first-line.
- Inherited
- yes
- Computed value
- as specified
- Animatable
- yes
- JavaScript syntax
- object.style.fontVariationSettings
Interactive Demo
Syntax
font-variation-settings: normal | <string> <number>
Values
- normalText is laid out using default settings.
- <string> <number>When rendering text, the list of variable font axis names is passed to the text layout engine to enable or disable font features. Each setting is always one or more pairs consisting of a <string> of 4 ASCII characters followed by a
indicating the axis value to set. If the <string> has more or fewer characters or contains characters outside the U+20 - U+7E code point range, the whole property is invalid. The <number> can be fractional or negative, depending on the value range available in your font, as defined by the font designer.
Example
Browser Support
The following information will show you the current browser support for the CSS font-variation-settings property. Hover over a browser icon to see the version that first introduced support for this CSS property.
This property is supported by all modern browsers.
Desktop
Tablets & Mobile
Last updated by CSSPortal on: 1st January 2026
