unifont
  • All fonts Browse or filter the whole catalogue
  • Compare providers One family, every CDN, side by side
  • Documentation Install, providers, custom providers
  • HTTP API The endpoints this site is built on

About unifont

What unifont is, who maintains it, and what this site is for.

unifont is an open-source JavaScript library for reading font metadata from font CDNs.

Google Fonts returns a stylesheet you have to parse. Fontshare returns JSON, with its own names for weights. Fontsource publishes to npm. And Adobe needs a Typekit project id.

unifont puts one interface over all of them: ask for a family and you'll get weights, styles, subsets, unicode ranges and @font-face data back in the same shape, whichever provider answered.

It's deliberately small. It reads metadata and hands it to you. It doesn't download font files, subset them, generate a build pipeline, or cache anything on your behalf.

Who makes it

unifont is maintained by Daniel Roe, with qwerzl and florian-lefebvre, at github.com/unjs/unifont. It's published to npm as unifont under the MIT licence, and there's no company behind it and nothing to sign up for.

It's used by @nuxt/fonts and fontless, which wrap it to download, self-host and metric-match fonts automatically in Nuxt and Vite apps. If you want fonts to work on a site rather than to query font metadata yourself, those are the better starting point: Reducing layout shift shows how to set one up.

What this site is

unifont.dev is the project site, and it's powered end to end by the library it documents. The catalogue is listFonts(), each family page is getFontProperties() and resolveFont(), and every face on the site was resolved at build time.

Every page here is also an HTTP endpoint. The catalogue, the provider comparison and each family page are thin layers over the public API, which needs no authentication. There's an MCP server at /mcp for agents, an OpenAPI description of every endpoint, and a machine-readable index of the site. Ask any prose page for text/markdown, or append .md to its path, and it answers in markdown.

Font data and licensing

Font metadata and font files belong to the foundries that made them and are licensed by them, not by us. This site never proxies or re-hosts font binaries: every file URL in a response points at the provider's own CDN. Check a family's licence with its foundry before shipping it.

Where the catalogue comes from

The catalogue is a cache of what each provider's own API answers, not a copy of it. Family indexes are read from the providers, held for an hour and refreshed in the background; measured transfer sizes are held for a week; nothing is kept beyond what makes the site answer quickly. A build primes the same cache so a cold deployment doesn't call five providers on its first request. Providers are asked in their documented ways, and no result is attributed to a provider that didn't answer it.

The font CSS this site serves is for reading, copying and scripting, and for its own pages. It isn't a font CDN: a <link rel="stylesheet"> pointing here from another site is refused, because that would put someone else's traffic through our origin and through the providers' terms. Resolve the family with unifont and serve the CSS from your own origin.

The public API is best-effort infrastructure for scripts, editor plugins and CI checks. It may be rate-limited or withdrawn, so if a deployment of yours depends on font resolution, install unifont and run it yourself, or self-host the CORS proxy.

Stacks live in your account

A stack you publish is a dev.unifont.stack record written to your own atproto account, through OAuth against your own server. This site never holds it: it reads records back from the accounts that own them, and finds them through constellation, a public index of links between records. Delete the record anywhere that speaks atproto and it is gone from here too, because there was never a second copy.

The write happens in your browser, against your own server, so there is no session here to keep: the only thing this site publishes about it is the client metadata document your server reads to identify the app.