Upload your own fonts (TTF, OTF, WOFF, WOFF2) – preview & generate @font-face CSS with data URI
Supported: TTF, OTF, WOFF, WOFF2 (max 5MB)
Want to embed this font uploader on your website? Use this code:
Learn the syntax, formats, and best practices for using custom fonts on the web.
Read Tutorial →How to use font-display, preload, and fallbacks for better performance.
Read Tutorial →What they are and how to use them for endless weight/style variations.
Read Tutorial →| Feature | Our Tool | Tool A | Tool B |
|---|---|---|---|
| Free & unlimited | ✅ | ✅ | ❌ (limit) |
| Upload custom fonts (TTF, OTF, WOFF, WOFF2) | ✅ | ✅ | ✅ |
| Live preview with size/weight/style | ✅ | ✅ | ❌ |
| Line height & letter spacing | ✅ | ❌ | ✅ |
| Color & background picker | ✅ | ✅ | ✅ |
| Base64 data URI in @font-face | ✅ | ❌ | ✅ |
| Download CSS file | ✅ | ❌ | ✅ |
| Client-side / private | ✅ | ❌ | ✅ |
TTF, OTF, WOFF, and WOFF2. Most modern browsers support these formats. WOFF2 is recommended for best compression.
No! Everything happens in your browser. Your font file never leaves your device. The tool uses the FileReader API and FontFace to load the font locally.
The CSS includes the entire font file as a base64 string inside the src property. This is a self‑contained way to embed the font directly in your CSS – useful for demos or small projects, but not recommended for production due to size.
Yes! Copy the CSS and paste it into your stylesheet. The font will be embedded as a data URI, so no separate font file is needed. However, be mindful of file size – large fonts can bloat your CSS.
Custom fonts give your website a unique identity. They allow you to match your brand typography exactly, create a consistent user experience, and stand out from the crowd. With the @font-face rule, you can embed any font and use it just like a system font.
Use your own fonts to reinforce your brand image.
WOFF2 offers excellent compression; use data URIs only for small fonts.
Ensure you have the right to embed any font on your website.
Tools to master web typography