Extract a Website Font Stack and Fallbacks
Learn how to identify a website's font families, match each role to a fallback, and document a practical CSS font stack.
extract a website font stack and fallbacks
To extract a website font stack and fallbacks, inspect the family assigned to each major text role, then record the observed font, a recommended fallback, and the generic family at the end. Check body text, headings, controls, code, and editorial text separately because one website can use several stacks.
Identify each text role
Start with body copy and record the declared family, weight, size, line height, and letter spacing. Then inspect headings, navigation, buttons, forms, captions, metadata, numbers, and code. Look for a different family, weight, or variant in each role.
Check italic and condensed styles separately. A browser may synthesize a style when the requested file is unavailable, so do not assume that a visual difference proves a separate font file. Also distinguish a family that is visibly used from a family that is merely loaded by the page.
A useful inventory has four columns: role, observed family, recommended fallback stack, and notes. In the notes, explain whether the fallback was chosen for similar width, x-height, tone, or availability.
The captured Linear reference lists Inter Variable, Berkeley Mono, and Tiempos Headline. Inter Variable is identified as the primary sans serif in this captured typography system. This is evidence about the supplied capture, not a claim about every page or state on the site.
Captured pages
Fonts captured on linear.app
- Inter Variable
Weight 400
- Berkeley Mono
- Tiempos Headline
Choose practical fallbacks
Put the most specific available family first, followed by a close system alternative and then a generic family. For example:
For a serif display role:
For code:
Do not select a fallback because its name sounds similar. Compare x-height, average character width, punctuation, numeral shapes, stroke contrast, and common words. A font that is too wide can change line wrapping and make buttons or headings taller.
Verify the fallback visually
Render a short specimen containing uppercase and lowercase letters, numerals, punctuation, a long sentence, a heading, and a button label. Keep size, weight, line height, and tracking constant while comparing the observed family with two or three candidates.
Check whether headings keep the same line count, buttons still fit, paragraphs have similar density, and numerals remain consistent. Test a blocked-font state as well. If the fallback causes large layout movement, choose a closer alternative or review font metrics that can reduce the shift.
Record certainty honestly. You can call a family observed when the capture supports it. Call a fallback recommended when you selected it for compatibility. Do not present your reconstruction as the site's official design system.
Add a final implementation check before handing it off. Confirm that each CSS declaration uses the intended role, that every requested weight has a matching file or a deliberate system fallback, and that the browser does not synthesize an unexpected bold or italic. Save screenshots of the primary-font and fallback states so later spacing changes can be traced to typography rather than mistaken for layout bugs.
Use this in your AI agent
> Inspect the captured website typography by role. Return the observed font family, variants, sizes, weights, and line heights for body text, headings, controls, code, and editorial text. Then propose a CSS fallback stack for each role, explain each fallback choice, and separate observed details from recommendations. Include a compact specimen for checking wrapping and button fit.
Install Fudge for your AI agent to run this typography check from your agent.
How should I choose the closest fallback when the original website font is unavailable?
Choose by visual behavior rather than category alone. Compare x-height, average character width, stroke contrast, numeral shapes, punctuation, and the appearance of words from the real page. For interface text, width and x-height usually matter most because they affect wrapping and control height.
Render a heading, paragraph, button label, and number string at the same size, weight, and line height. Reject candidates that add a heading line, cause a label to overflow, or look substantially darker. Order the closest available font first, then broader system choices, with the generic family last. Label this stack as your recommendation unless the page itself declares those fallbacks.
Also test the fallback while the page is loading and after the primary font is blocked. Compare button heights, heading breaks, paragraph length, and perceived weight. If the change is large, choose a closer metric match or adjust the affected role deliberately rather than applying a global spacing fix.
What should I include in a font-stack handoff for another designer or developer?
Use a role-based table. For body text, headings, navigation, buttons, code, numbers, and editorial text, record the observed family, variants, weight, size, line height, tracking, recommended fallback stack, sample text, and confidence.
Add checks for heading line breaks, button fit, paragraph density, numeral alignment, italic behavior, and the appearance while the primary font is unavailable. Mark each fact as observed, likely, or recommended. That distinction prevents a compatibility choice from being mistaken for an official website decision.
Include the CSS declarations, the files or sources that still need verification, and screenshots showing the primary and fallback states. Note which weights are essential and what should happen if one is missing. Ask the next implementer to test long labels, error messages, tables, and narrow screens before treating the handoff as complete.