Webfont Generator

@font-face Webfont Generator

Variable fonts, WOFF2 and CSS in one click

Drop your TTF, OTF, WOFF or WOFF2 files — including variable fonts — choose your settings, and download a ready-to-host bundle with WOFF2, WOFF, a complete stylesheet.css and a live demo page.

Drop fonts here or click to browse

TTF, OTF, WOFF, WOFF2 and variable fonts — multiple files allowed

100% client-side

Conversion runs entirely in your browser using WebAssembly. Your fonts are never uploaded.

Variable fonts & all formats

TTF, OTF, WOFF and WOFF2 in — optimised WOFF2 out, with full variable-font axis support (wght, wdth, slnt, ital).

Production-ready output

Ships a stylesheet.css with the right font-display, optional local() and a demo.html so you can drop the bundle straight into your project.

What is a webfont generator?

A webfont generator turns desktop or downloaded font files (TTF, OTF, WOFF, WOFF2 — including modern variable fonts) into the formats browsers can load over the web — primarily WOFF2 today, with WOFF as legacy fallback — and produces matching CSS @font-face declarations so you can self-host the typography of your website.

Why self-host fonts?

Self-hosting gives you full control over performance, privacy and reliability. There is no third-party request to Google Fonts (helpful for GDPR), no extra DNS lookup, you can preload the file, and you decide exactly which weights, styles and axes ship with your site.

How the conversion works

WOFF2 wraps your TTF/OTF outlines in a Brotli-compressed container designed specifically for the web — typically 30 % smaller than WOFF and over 50 % smaller than the raw TTF. WOFF is an older zlib-compressed wrapper, kept around as a fallback for very old browsers. Our generator runs Google's official WOFF2 encoder and decoder compiled to WebAssembly, so the conversion happens locally inside your browser. Drop in a WOFF2 you downloaded from Google Fonts and we transparently decode it back to a sfnt container before re-encoding — you never have to hunt for the original TTF.

What you get in the bundle

  • Fonts in WOFF2 (and optionally WOFF/TTF) for every uploaded face — including variable fonts kept as a single small file.
  • A complete stylesheet.css with one @font-face rule per file, the correct format() hints, font-weight ranges, font-style, font-stretch, font-display and optional local().
  • A demo.html page so you can preview every weight, style and axis at multiple sizes before going live.
  • Optional Base64 embedding to ship the font inline in your CSS for offline-first or single-file scenarios.

Privacy & licensing

Files never leave your device — everything is processed in your browser. Always make sure your font's license allows webfont embedding before publishing it on your website.

Frequently asked questions