28

How to Disable Gutenberg and Enable the Classic Editor in WordPress

Powered by WPCodeBox

This WordPress snippet efficiently disables Gutenberg, allowing you to use the Classic Editor without installing additional plugins.


<?php 

// Disable Gutenberg for posts
add_filter('use_block_editor_for_post', '__return_false', 10);

// Disable Gutenberg for pages and other post types
add_filter('use_block_editor_for_post_type', '__return_false', 10);
We also have a video in which we use this snippet:

Other Snippets

WPCodeBox is a WordPress Code Snippets Manager that allows you to share your WordPress Code Snippets across your sites.