Skip to content
Performance & Accessibility

Font Subsetting, Done Properly

Removing unused characters from font files so they download faster.

Marcus Adeyemi Technical Director 2 min read 24 views
Font Subsetting, Done Properly

Why does it matter?

Full font files carry characters most sites never use, and subsetting can cut font weight dramatically.

What are the numbers?

  • Subsetting keeps only the glyphs a site needs
  • unicode-range lets browsers download only the ranges in use
  • WOFF2 is the compressed format for web fonts
  • font-display controls how text renders while fonts load

What should I do?

  1. Subset fonts to the languages you support
  2. Serve WOFF2
  3. Use unicode-range for multilingual sites
  4. Set font-display to swap or optional
  5. Preload only critical font files
What to do and what to avoid with font subsetting, side by side
Good practice against the usual mistakes, from the sources listed below.

What should I avoid?

Avoid:

  • Serving full multilingual fonts
  • Loading many weights and styles
  • Blocking render on fonts
  • Subsetting so far that content breaks

When should I get help?

Short answer Bring in help when fonts dominate page weight.

Where this comes from

The figures and practices above come from the sources listed.

Working on something like this?

We take on Performance & Accessibility work for teams who want it done once, properly. Tell us what you are building and we will tell you honestly whether we are the right studio for it. Start a project.

Where to go next

Spotted something wrong? Report an error on this page. We correct on the page and say what changed.

All services

The work behind this article, and what it costs.

Marcus Adeyemi

Builds and maintains the web work. Writes about front-end architecture, performance, accessibility and the unglamorous parts of keeping a site alive.

Keep reading

More in Performance & Accessibility