Embed Google Fonts
Explore this tool and check the official listing for its latest features and requirements.
About this tool.
Embed Google Fonts tries to automatically replace registered Google Fonts from themes and plugins with local versions, directly loaded from your own server.
Contribute : https://github.com/moewe-io/embed-google-fonts
Notes
- The first request might be very slow, as fonts are downloaded and cached the first time they are requested.
- This doesn’t automatically replace all your Google fonts with local versions. If a plugin/theme doesn’t use WordPress wp_enqueue_style it probably won’t work.
- Loaded fonts are not optimized, means, the whole font including all subsets is loaded
- See FAQ for instructions to use locally hosted fonts directly and avoid using Heroku
Thank you: Fonts are downloaded using: https://gwfh.mranftl.com/fonts
Frequently asked questions.
How to use locally stored fonts directly?
It is possible to avoid using Heroku and directly use locally hosted fonts.
Easy way:
- Let the plugin download the fonts Click the button in the plugin list overview 😉
Custom way:
- Create a folder “embed-google-fonts” in your “wp-content” folder
- For every font create a subfolder, i.e. “embed-google-fonts/open-sans/” Create a file “embed-google-fonts/open-sans/_font.css”
- Edit your “_font.css” to include rules for loading your local font
Does this work with every theme and plugin?
No, themes and plugins must use wp_enqueue_style to load Google Fonts. Just try it, if it works, than you are fine.
Does it work with caching plugins?
Generally yes. You may exclude some files, if there are problems.
Does it work with WP Rocket?
Yes, it is working with WP Rocket.
Does it work with WP Fastest Cache?
If you are using WP Fastest Cache , you should create an exclude CSS rule for “_font.css”
Does it work with Divi?
You have to disable
- Improve Google Fonts Loading and