• Skip to primary navigation
  • Skip to main content
OsomCode

OsomCode

Awesome code tutorials for WordPress and Genesis

  • Subscribe
  • My account
    • Edit profile
    • Favorites
    • Update credit card
  • Login

How to disable the WordPress font library

Learn in this tutorial how to disable the WordPress font library using code.

WordPress 6.5 introduced quite a few new features, one of the most prominent is the font library.

When you are using a block-based theme (for the moment), this feature allows you to edit, add and manage theme fonts directly from the style editor.

additional font management WordPress font library

This is a fantastic improvement that opens up many customization options in a very simple way.

So, you may want to disable it on client sites where all the necessary fonts are already configured to prevent them from adding more or removing the existing ones.

Here’s how:

Snippet to disable the WordPress font library user interface

Add the following code at the end of functions.php or in your functionality plugin:

To see this and another 1097 code snippets of this website, login or subscribe here.

It’s as simple as that.

Conclusions

The arrival of the font library makes it possible for any user to manage the fonts of a website. Therefore, if you prefer to avoid possible confusion on client websites, you already know how to disable it.

If you have any question, please leave it in the comments. And if you want to give me a suggestion for future snippets, please send it through the contact form.

Benefits of being a subscriber. 🙂


PHP WordPress

To leave read and make questions about this code, you can login or register.

  • About OsomCode
  • FAQ
  • Contact

Legal Notice · Privacy Policy · Cookie Policy · Terms and conditions
Copyright © 2026

close-icon

Lost your password?