Fonts are often the heaviest thing on a page after images, and the one that most visibly changes how a page loads. Get them wrong and visitors see invisible text, a sudden jump when the real font arrives, or a page that feels slow even when it isn’t. Get them right and nobody notices them at all, which is the goal.
Every Fonterio web download includes WOFF2 files and a ready-made CSS snippet. This is the checklist we use when we put those files on a real site.
1. Serve WOFF2, and only WOFF2
WOFF2 is a compressed font format supported by every browser in current use. It is typically 30% smaller than WOFF and far smaller than OTF or TTF. You no longer need to list fallback formats in @font-face — one WOFF2 source per style is enough. Keep the OTF and TTF files for desktop use; they don’t belong on your server.
@font-face {
font-family: 'Plain Sans';
src: url('/fonts/plain-sans-regular.woff2') format('woff2');
font-weight: 400;
font-style: normal;
font-display: swap;
}2. Choose a font-display strategy
The font-display descriptor decides what the browser shows while the font downloads. swap shows a fallback immediately and swaps in the web font when it arrives — the right default for body text, because people can start reading at once. optional uses the web font only if it arrives almost instantly and otherwise keeps the fallback for that page view; it is a good choice for secondary text where a late swap would be more distracting than helpful. Avoid block for anything people need to read.
3. Preload the one or two fonts above the fold
Browsers only discover a font when they find CSS that uses it, which can be late. A preload hint tells the browser to fetch the file straight away. Preload only the styles that render in the first screen — usually the body regular and the heading weight. Preloading everything competes with images and scripts and makes the page slower, not faster.
<link rel="preload" href="/fonts/plain-sans-regular.woff2"
as="font" type="font/woff2" crossorigin>4. Load fewer styles
Each weight and italic is a separate file. A site that loads Light, Regular, Medium, Bold and their italics is downloading ten fonts before anyone reads a word. Most sites need three or four styles. If you genuinely need many weights, a variable font is usually smaller than four or more static files and gives you every weight in between.
5. Subset when you know the languages
If your site is only in English, you don’t need every accented character a family supports. Subsetting removes unused glyphs and can halve the file size. The unicode-range descriptor lets you split a family into several files, so a browser only downloads the extended set when a page actually contains those characters. Subsetting modifies the font file, so check that your license allows it — ours does, for your own web use.
6. Cache fonts for a year
Font files almost never change, so they should be cached aggressively. Serve them with a long cache lifetime and change the filename when you update a font. If the files live on another domain, that server must also send the right CORS header, or browsers will refuse to use them.
Cache-Control: public, max-age=31536000, immutable
Access-Control-Allow-Origin: https://your-site.com7. Match the fallback to stop layout shift
When the web font swaps in, text can reflow if the fallback font has different proportions. Modern CSS lets you adjust a local fallback so its metrics match your web font closely, which removes most of that jump. Define a fallback face with size-adjust, ascent-override and descent-override, then list it right after your web font.
@font-face {
font-family: 'Plain Sans Fallback';
src: local('Arial');
size-adjust: 104%;
ascent-override: 92%;
descent-override: 24%;
}
body {
font-family: 'Plain Sans', 'Plain Sans Fallback', sans-serif;
}The checklist
- WOFF2 only, one source per style.
- font-display: swap for body text, optional for secondary text.
- Preload one or two above-the-fold styles, with crossorigin.
- Three or four styles, or one variable font.
- Subset to the languages you publish in.
- Cache for a year; rename on update; send CORS headers from other domains.
- A metric-matched fallback to prevent layout shift.
Self-hosting a premium family needs a Web license sized to your monthly page views. If you are not sure which tier fits, read our two-minute licensing guide. Free families can also be used straight from the Fonterio CDN if you would rather not host files at all.
- web fonts
- performance
- WOFF2
- CSS
- guide