A complete guide to variable font technology
Variable fonts: What they are, How they work and benefits
Variable fonts have transformed modern web design and typography by combining an entire font family—spanning multiple weights, widths, and styles—into a single, unified file. To simplify testing, fine-tuning, and implementing these dynamic typefaces.
What are variable fonts?
Variable fonts are font files that contain many variations (in size, weight, or height) of a typeface inside a single font file.
Traditionally, a font family might require separate files:
• Roboto-Regular.ttf
• Roboto-Medium.ttf
• Roboto-Bold.ttf
• Roboto-Italic.ttf
With a variable font, these variations can be stored in one file, and the application can adjust the font along one or more variation axes.
Imagine a variable font with a weight axis:
Weight: 100 (Thin) ───────────── 900 (Bold)
Instead of selecting only predefined weights such as 400 or 700, you could request:
1{
2 font-weight: 550;
3}The font can generate the appropriate intermediate design within the next font properties.
| Axis | Tag | What it controls |
|---|---|---|
| Weight | wght | Thin → Bold |
| Width | wdth | Condensed → Expanded |
| Slant | slnt | Upright → Slanted |
| Italic | ital | Upright → Italic |
| Optical size | opsz | Adjusts design for different text sizes |
There can also be custom axes defined by the font designer.
For example:
| Weight | Width | Optical size | Slant |
|---|---|---|---|
| 400 | 90 | 14 | -5 |
These values can be combined for particular font formating.
Why variable fonts are useful?
Fewer font files - One variable font can replace many static font files of different forn properties.
More accurate font styling - Instead of choosing only Regular or Bold, you can use any values between them.
Responsive typography - This technologe lets websites dynamically change font width, weight, or optical size depending on screen size or context.
How variable fonts work technically?
Variable fonts are based on OpenType technology. They use tables such as:
| Name | What it does |
|---|---|
fvar | Defines variation axes |
gvar | Glyph variations |
hvar | Horizontal metrics variations |
mvar | Metric variations |
stat | Describes styles/axis values |
For example, the fvar table can be defined like that:
| Axis | Minimum | Default | Maximum |
|---|---|---|---|
wght | 100 | 400 | 900 |
The font engine then adjusts the appropriate glyph outlines and metrics to the requested value.
Variable fonts and Aspose.Font
Aspose offers a free web-based tool: the Aspose Variable Font Viewer.
This browser-based application allows designers and developers to interactively inspect, adjust, and copy CSS code for variable fonts in real time.
Key features and functionality
- Interactive variation axis sliders Traditional typography requires separate files for Regular, Bold, Condensed, or Light font weights. The Variable Font Viewer extracts and exposes all OpenType variation axes embedded within a file, offering real-time sliders for both standard and custom dimensions:
- Weight (
wght): Fine-tune stroke thickness continuously from thin (100) to heavy (1000). - Width (
wdth): Expand or condense letterforms smoothly. - Optical Size (
opsz): Adjust stroke contrast and proportions for small caption text versus large displays. - Slant (
slnt) and Italic (ital): Control letter angle and italic attributes dynamically. - Custom Axes: Detects and renders custom parametric axes defined by the font foundry.

- Live text and layout preview
- Editable Preview Text: Type custom copy directly into the preview area to see how specific characters, headlines, or body text behave under different axis combinations.
- Font size and line height adjustments: Test typography in realistic layouts by modifying line height and font size alongside variable axis settings.
- Named instances (Presets)
Most variable fonts come pre-configured with Named Instances (preset styles such as Regular, Bold Condensed, or Display Light). The Aspose viewer detects these built-in presets, enabling instant switching with a single click without manually tweaking individual sliders.
- Automated CSS code generation
- As you adjust sliders or select named instances, the app dynamically constructs valid CSS declarations, including
font-weight,font-stretch,font-optical-sizing, and the low-level font-variation-settingsproperty. - A one-click “Copy CSS” button allows you to instantly copy the generated code snippet into your web project or design system.

- Built-in library for visualisation
- Sample fonts. Test functionality immediately using built-in popular variable fonts such as Roboto Flex, Recursive, Inter, Source Serif 4, Playfair Display, Work Sans, Nunito, and Oswald.
- Custom font uploads. Drag and drop your own local TrueType (
.ttf) or OpenType (.otf) font files to inspect custom type designs.
How to use the Aspose Variable Font Viewer
- Select or upload a font: Choose one of the pre-loaded sample variable fonts or upload a local .ttf or .otf file.
- Inspect and adjust axes: Use the live sliders to modify weight, width, optical size, slant, or custom axes. Alternatively, select a predefined Named Instance.
- Customize preview text: Modify the preview text, size, and line height to evaluate readability and aesthetics.
- Export CSS: Click Copy CSS to copy the generated stylesheet rule and paste it directly into your web stylesheet.
Where can I get variable fonts?
You can get variable fonts from several reputable sources, depending on whether you need free/open-source fonts, web fonts, or commercial typefaces.
- Google Fonts - free and open source
Google Fonts collection is one of the easiest places to find variable fonts. Many families, such as Roboto, Inter, and Source Sans 3, are available with variable axes.
Google marks variable fonts and the number of variations of the font.

It also lets you test those variations right on the spot.

- Adobe Fonts - large professional collection
Adobe Fonts has a dedicated selection of variable fonts. Adobe currently describes its library as containing more than 100 variable typefaces, with variable fonts allowing many styles to be generated from a single font.
- Font foundries and commercial marketplaces
For premium fonts, variable versions are increasingly offered directly by type foundries and font marketplaces.
- GitHub and open-source projects
Many open-source variable fonts are distributed through GitHub repositories. This is particularly useful if you’re a developer and need the actual .ttf, .otf, or .woff2 files rather than simply using a web-font service.
For example, Adobe’s Source Han family includes variable OpenType fonts and corresponding TrueType and WOFF2 versions for different languages.