Picture the scene. You have just rolled out a smart new heading font on your website. It looks sharp on your fast office connection, so you move on. Then a visitor on a patchy rural 4G signal, somewhere out on the Costa Blanca or in the Lake District, loads the page. The font file stalls, the browser reaches for its backup, and suddenly every headline is enormous.
It is a small problem that makes a site look careless, and there is a neat CSS fix for it.
Why does the backup font look so big?
When you register a custom font, you normally list a safe alternative after it in the font stack. Designers often pick the browser’s built-in interface font because it is guaranteed to exist. The catch is that different typefaces are drawn at different sizes, even when the CSS asks for the same number of pixels. A fallback with generous proportions can make a carefully balanced heading look like it is shouting.
Many of us have tried to solve this by setting a different heading size for the backup font. CSS has no way to say “use this size only if the font fails to load”, and even the newer conditional syntax cannot detect a failed download. That leaves us needing another route.

Resize the backup font in four steps
The trick is to turn the backup font into a font of its own, with a size correction built in.
- Register your real font as usual, with a
font-displaysetting so text appears straight away. - Register a second font under a new name, such as “NewFont Fallback”, and point it at a typeface already installed on the visitor’s device using
local(). - Add the
size-adjustdescriptor to that second rule to shrink or enlarge the backup until its headings match the real thing. - List both names in your headings’ font stack, followed by a generic family as a last resort.
@font-face {
font-family: "NewFont";
src: url("/fonts/NewFont-Variable.woff2") format("woff2");
font-display: swap;
font-weight: 200 700;
}
@font-face {
font-family: "NewFont Fallback";
src: local("Arial");
size-adjust: 88%;
}
h1, h2, h3 {
font-family: "NewFont", "NewFont Fallback", sans-serif;
}
The 88% figure is only an example. You tune it by eye: temporarily remove the real font from the stack, compare the two versions side by side, and nudge the percentage until the headings take up about the same space. Naming a specific, widely installed font such as Arial is the safer choice, because pointing local() at a generic keyword like system-ui does not behave consistently across browsers.
Jargon buster
Fallback font: the backup typeface a browser uses while your custom font is loading, or if it never arrives.
size-adjust: a setting inside @font-face that scales every character in a font up or down by a percentage.
Layout shift: the jump you see when text changes size after the page has already appeared, pushing other content around.
Font stack: the ordered list of fonts in a font-family rule. The browser works down the list until it finds one it can use.

What this means for your website
Most business owners never see a failed font load, because their own devices have the file cached. Your customers do not have that luxury. Holiday-let guests on roaming data, shoppers on a train, and clients behind a strict company firewall are all more likely to meet your fallback than you are.
Ask your web developer to test your pages with the custom fonts blocked, using the browser’s developer tools. If the headings look cramped, oversized or broken, a short corrective rule like the one above takes minutes to add. It also helps stop text jumping around as the page settles, which makes a site feel more polished on any connection, whether visitors arrive from Manchester or Valencia.
When did you last look at your site with the fonts switched off?










