Fontkit

github.com ↗

A JavaScript font engine for glyph layout, paths and PDF subsets.

SI Score
80/100
Pricing
Open Source AI reading, not confirmed
Free plan
Yes AI reading, not confirmed
Sign-up required
Not required AI reading, not confirmed

Ask SI about Fontkit

Answers use saved listing facts and recorded sources.
Homepage screenshot
Screenshot of the Fontkit homepage

What it does

Fontkit is a font engine for Node and the browser. It reads several font formats and exposes glyph layout, metrics, outlines, color glyphs and font subsetting through a documented programming interface.

Fontkit reads font data in Node.js or the browser and returns glyphs, metrics and outlines for your own application. After installing the npm package, open a font with fontkit.open or create it from a buffer, then call font.layout on the text. The resulting glyph run contains positions as well as glyphs, including substitutions and kerning that a simple character lookup would miss.

Individual glyph paths can become SVG path data or render to a graphics context. If the application only needs selected formats, import fontkit/core and register the required format classes rather than loading every built-in format.

Its subsetting output has a narrower use: the generated minimal fonts are designed for PDF embedding and omit tables needed by ordinary standalone fonts. They should not be treated as ready-to-use webfont conversions. Fontkit is a free MIT-licensed library and needs JavaScript integration.

Strengths

  • Combines font parsing with layout, metrics and path access.
  • Documents format-specific imports and PDF-oriented subsetting.

Watch out for

  • Generated subsets may not work as standalone fonts.
  • Requires a JavaScript integration.

Best for

  • Developers generating PDFs or custom font graphics.
  • Tools inspecting layout and glyph metadata.

Sources