Skip to content

How To Disable Gutenberg Editor with Code.


Do you want to disable Gutenberg Editor completely and want to use some other page builder?

Why Disable Gutenberg ?

there can be various reasons why you want to get rid of the new WordPress Gutenberg Editor and some of them are listed below:

  • Gutenberg is Hard to use.
  • Used to with Elementor / Divi / Other Page Builders.
  • Gutenberg is boring.
  • Lack of responsive settings.
  • Not much Prep-buit templates.

you can use this line of code to disable Gutenberg editor completely. make sure to paste that in your functions.php file.

add_filter('use_block_editor_for_post', '__return_false');

and if you want to disable it from specific pages then go with the code written below.

function itdoctorz_disable_gutenberg_for_post_type( $is_enabled, $post_type ) {
	if ( 'your_post_type' == $post_type ) {  // Change ‘your_post_type’ to your CPT slug for which you want to disable Gutenberg Editor.
        		return false;
	return $is_enabled;
add_filter( 'use_block_editor_for_post_type',  ‘itdoctorz_disable_gutenberg_for_post_type’, 10, 2 );

I hope this helped and you are able to achieve what you were looking for. If yes, then please comment down below and make sure to follow us on YouTube and join us on Facebook .

Scan the code