How to Disable Gutenberg

gutenberg-is-coming

Gutenberg will soon be added to the WordPress core and lots of websites out there will not be ready for it when it hits. Many small businesses will not have time or budget to test and update client sites so that it is compatible with Gutenberg.

For those wast majority that is still not ready to convert all sites and content to Gutenberg here is one snippet that you could add to your theme’s functions.php file that will disable Gutenberg for you.

Disable Gutenberg Completely with a Code

To completely disable Gutenberg, add the following line directly in the functions.php or with a snippets plugin:

add_filter('use_block_editor_for_post', '__return_false');

That is the recommended way of disabling Gutenberg. It simply returns a value of false to Gutenberg’s gutenberg_can_edit_post_type filter, which then disables Gutenberg for all post types, or simply putted, completely.

Disable Gutenberg with a Plugin

The easiest way to disable Gutenberg is to install a free Disable Gutenberg plugin. It is a simple plugin focused on one thing: disabling Gutenberg and restoring the default classic WP Editor screen. Just enable the plugin, choose your options and done. Options include:

  • Disable Gutenberg completely (all post types)
  • Disable Gutenberg only on specific post types
  • Disable Gutenberg for specific user roles

So it is flexible yet simple and easy to use.

Disable "Try Gutenberg" nag across admin screens

The above solutions are straightforward enough, but what if you want to go a bit further and hide the "Try Gutenberg" nag across all admin screens? For that you can install the Dismiss Gutenberg Nag plugin.

Disclaimer

Both WordPress and Gutenberg are constantly changing so be sure to test the above code and plugins with the latest version of WordPress and Gutenberg before implementing on a live site.

Enjoy!

1 Star2 Stars3 Stars4 Stars5 Stars (3 votes, average: 3.67 out of 5)
Loading...Loading...

Leave a Reply

Your email address will not be published. Required fields are marked *

 

butrick_erica