Hey there! If you’re here, I’m guessing the WordPress Block Editor (or Gutenberg, as it’s also known) isn’t quite clicking with you.
Don’t worry—you’re not alone! Many of us who started out with the Classic Editor miss that simple, straightforward way to create posts and pages.
The Block Editor has its perks, but if you want to go back to the Classic Editor, I’ll walk you through how to do it without adding any plugins.
Let’s get started!
Why Disable the Block Editor?
When the Block Editor first came out, I remember thinking, “Oh no, what happened to my WordPress?” Everything was suddenly in blocks, and it felt more like a jigsaw puzzle than a text editor!
If you’re more comfortable with the Classic Editor’s interface, switching back might just make your WordPress life easier, especially if you’re managing content-heavy sites or prefer a minimal editing experience.
Now, let’s look at a quick and easy way to bring back the Classic Editor without plugins.
Step-by-Step: How to Disable the Block Editor with Code
You don’t need to be a coding wizard to do this—it’s a simple tweak! We’re going to add a small snippet of code to your functions.php
file to disable the Block Editor across your entire WordPress site.
Step 1: Access Your Theme’s functions.php
File
- Log in to WordPress and go to Appearance > Theme Editor.
- On the right, find the file called
functions.php
. This is where we’ll add our code snippet. (If you’re using a child theme, make sure you’re editing the child theme’sfunctions.php
file.) - Important: Always back up your
functions.php
file before making any changes. This way, if something goes wrong, you can easily restore it. (I learned this the hard way once when I accidentally took my site offline with a mistyped line of code!)
Step 2: Add the Code to Disable the Block Editor
Here’s the magic code to bring back the Classic Editor:
add_filter('use_block_editor_for_post', '__return_false');
- This little line tells WordPress to disable the Block Editor and switch to the Classic Editor for all your posts and pages.
- After adding the code, save the changes.
Now, when you go to create a new post or edit an existing one, you’ll see the Classic Editor back in action! It’s like welcoming back an old friend.
Extra Option: Disable Block Editor for Specific Post Types Only
Maybe you like the Block Editor for pages but not for blog posts, or vice versa. You can target specific post types with this code:
function disable_block_editor_for_post_type($use_block_editor, $post_type) {
if ($post_type === 'post') {
return false;
}
return $use_block_editor;
}
add_filter('use_block_editor_for_post_type', 'disable_block_editor_for_post_type', 10, 2);
In this example, the Block Editor is disabled only for posts. If you want to disable it for pages, just change 'post'
to 'page'
.
Step 3: Test It Out
Head over to Posts > Add New or Pages > Add New in your WordPress dashboard to see if the Classic Editor is now in place. You should be greeted by the familiar, clean editing screen we all know and love!
Bonus Tip: Re-enabling the Block Editor
Let’s say you’re feeling nostalgic one day and decide to give the Block Editor another try. All you need to do is go back into your functions.php
file and remove the code we added above. Save the file, and your Block Editor will be back.
Final Thoughts
And that’s it! Disabling the Block Editor is a simple process, and you don’t need to worry about adding more plugins or weighing down your site.
When I first made this switch, it felt like a sigh of relief. The Classic Editor brought back that simplicity and focus on content creation, letting me get right to the writing without thinking about blocks, containers, or columns.
I hope this guide was helpful! If you run into any issues, feel free to reach out. And happy editing, however you choose to do it! 😊
Discover more from Prime Inspire
Subscribe to get the latest posts sent to your email.