# Webfont Subsetter (WOFF & TTF) > Shrink a font to the characters your site uses and get a WOFF file with its CSS unicode-range. Upload a TrueType font (TTF or WOFF) and keep only the characters you need: type them, paste a page's text, add Unicode ranges or tick common blocks. Variable fonts can be frozen at one weight. You get a WOFF 1.0 or TTF file with kerning kept as a kern table, the size saving and a ready @font-face rule with unicode-range. Part of usefulweb.app (https://usefulweb.app/). Part of [Lumina](https://lumina.usefulweb.app/) (ownerApp: lumina). Results are deterministic calculations from the inputs and the listed assumptions; the API returns exactly what the web page shows. ## Use it - Human interface: https://luminafontsubset.usefulweb.app/ (interactive tool at https://luminafontsubset.usefulweb.app/tool) - JSON API: POST https://luminafontsubset.usefulweb.app/api/v1/calculate with a JSON object of inputs (schema: https://luminafontsubset.usefulweb.app/api/v1/tool) - OpenAPI: https://luminafontsubset.usefulweb.app/openapi.json - MCP (Streamable HTTP): https://luminafontsubset.usefulweb.app/mcp - tool `lumina_font_subset` ## Inputs - font (file, required): Font (TTF or WOFF with TrueType outlines; up to 10 MB; uploaded to the server) - text (textarea): Characters or text to keep - ranges (text): Unicode ranges (e.g. U+0020-007E, U+00E9) - presets (multiselect): Common character blocks - format (select): Output format - kerning (boolean): Keep kerning (as a kern table) - axes (text): Freeze a variable font at (e.g. wght=700; empty = keep the default instance) ## Method - The requested code points are the characters of the text, the ranges and the ticked blocks (tab and line breaks ignored). Glyphs are kept for every code point the font maps, plus .notdef and all components of composite glyphs; glyph ids are renumbered densely. - The subset keeps head, hhea, maxp, hmtx, loca, glyf, a new cmap (formats 4 and 12), post 3.0, name, OS/2 and hinting tables. GSUB, GPOS, GDEF and variation tables are dropped. With axis values the outlines and advances of that instance are baked in (gvar applied, composites flattened) and OS/2 weight follows wght. - Kerning: for subsets up to 400 glyphs every pair runs through the font's own GPOS kern lookups (class kerning included) and the non-zero values go into a legacy kern table (format 0, up to 10900 pairs), which browsers apply when GPOS is absent. Frozen variable instances use the pair list at that location. - WOFF 1.0: each table is zlib-compressed when that makes it smaller and 4-byte aligned, with the original checksums; the file is unpacked again and must give the subset font byte for byte. WOFF2 needs a Brotli encoder, which this platform does not have in pure TypeScript, so WOFF2 is not offered. ## Limits - Check the font's license before publishing a subset: some licenses forbid modification or reserve the font name. Ligatures, alternates and mark positioning are not kept. CFF (PostScript-outline) fonts are not supported.