Customize typography on your documentation site with Google Fonts or self-hosted font files for headings, body text, and code blocks.
Set a custom font for your entire site or separately for headings and body text. Use Google Fonts, local font files, or externally hosted fonts. The default font varies by theme.
Configure fonts with the fonts property in your docs.json.
Google Fonts
Docfiy automatically loads Google Fonts when you specify a font family name in your docs.json.
docs.json
Copy
Ask AI
"fonts": { "family": "Inter"}
Local fonts
To use local fonts, place your font files in your project directory and reference them in your docs.json configuration.
Set up local fonts
1
Add font files to your project
For example, create a fonts directory and add your font files:
URL to your font source, such as https://docfiy-assets.b-cdn.net/fonts/Hubot-Sans.woff2, or path to your local font file, such as /assets/fonts/InterDisplay.woff2. Google Fonts are loaded automatically when you specify a Google Font family name, so no source URL is needed.
URL to your font source, such as https://docfiy-assets.b-cdn.net/fonts/Hubot-Sans.woff2, or path to your local font file for headings. Google Fonts are loaded automatically when you specify a Google Font family name, so no source URL is needed.
URL to your font source, such as https://docfiy-assets.b-cdn.net/fonts/Hubot-Sans.woff2, or path to your local font file for body text. Google Fonts are loaded automatically when you specify a Google Font family name, so no source URL is needed.