Skip to content

How to disable the widget block editor in WordPress?

WordPress introduced the Gutenberg block editor version 4.8 for editing posts and pages. After that, almost every update contains improvements to blocks and the Gutenberg interface. As part of full site editing, WordPress 5.8 introduced a widget-based block editor, removing the classic widget interface. In this article, we will explain why and how to disable the widget block editor in WordPress.

WordPress Widgets

The WordPress site has had a standard layout for quite a long time. A simple WordPress page contains a header, footer, main content, and a sidebar area. You can add widgets to the sidebar and footer area by going to the Appearance > Widgets menu in the WordPress admin panel. WordPress offered some widgets by default such as a text widget, custom HTML, latest posts, categories, etc. Your theme and plugins may offer custom widgets that you can showcase in the widget area.

Legacy Widget Area in WordPress
Legacy Widget Area in WordPress

This continued until WordPress 5.7, and the traditional widget area was removed in WordPress 5.8. You now have the popular Gutenberg block editor, which has replaced the traditional widget area. Instead of dragging and dropping widgets, you can insert Gutenberg blocks as widgets.

New widget block editor in WordPress
New widget block editor in WordPress

Managing Widgets in the Customizer

Similar to managing widgets under Appearance > Widgets, you can also add widgets to the supported area under Appearance > Customization > Widgets.

Old Widget Interface in Customizer
Old Widget Interface in Customizer
New widget block editor in customizer
New widget block editor in customizer

Why is the widget block editor a problem?

When Gutenberg came along, it created a lot of problems, such as slowing down the site. These issues have forced many users to disable the Gutenberg editor and continue using the old classic editor. Similarly, you will run into a lot of issues with the new widget block editor in WordPress.

  • You need to manually remove old obsolete widgets and replace them with new blocks. For example, you could insert sidebar ads using the old Custom HTML widget. Now you need to replace it with a custom HTML block in order for the widget to work properly. Otherwise, you will see errors when you open the widget section, as shown below. The error message will say something like “The ‘archives’ block encountered errors and may not work correctly. see developer tools for details.”
Widget bug in new editor
Widget bug in new editor
  • Your theme and plugins may use the old widget area and conflict with the new block widgets. You will see errors like “Note: wp_enqueue_script() was not called correctly. The “wp-editor” script should not be queued with the new widget editor (wp-edit-widgets or wp-customize-widgets). For more information, see Debugging in WordPress. (This post was added in version 5.8.0.) In /wp-includes/functions.php on line 5535.”
  • The new widget area will completely slow down your work and spinner loading forever. It can also crash your computer due to high browser memory usage.
Widget loading slowly
Widget loading slowly
  • You will be easily annoyed by searching and inserting widgets when you have multiple sidebars.
  • Some widgets, such as Custom HTML, were much easier to insert ad code than with the Custom HTML block.
  • If you have a custom sidebar, it may not be compatible with the new block-based widgets. For example, Custom Sidebars – Dynamic Sidebar Widget Area Manager will not work with the new editor and you need to revert to the old widget area to continue using the plugin.
  • Previously, you could save a separate widget and check the published content. However, you must save the entire area by clicking the Refresh button in the new interface.
  • You may find it difficult to manage widgets in the customizer compared to the old interface.
  • The new interface may have PHP bugs due to incompatibilities, and you may miss the accessibility features available in the old interface.
See also  How to Set Up Your WordPress Blog in HostGator?

How to disable the widget block editor in WordPress?

In any case, if you’re blown away by the new widget block editor, follow the options below to revert to the old widget area interface.

1. Using the Classic Widgets plugin

The first option is to use the official compatibility plugin from the developers of the WordPress community. Similar to the classic editor that allows you to use the classic interface instead of Gutenberg, you have the Classic Widgets plugin. This plugin will completely disable the new widget block editor interface and allow you to use the old interface.

  • Go to Plugins > Add New in your WordPress admin panel.
  • Find “classic widgets” Classic Widgets plugin from the authors of WordPress.
Install the Classic Widgets plugin
Install the Classic Widgets plugin
  • Install and activate the plugin.
  • This plugin does not have a settings page.
  • Once activated, it will automatically revert the block-based widget area to the old classic widget area.

Since this is an official WordPress plugin, you can expect this plugin to be available for at least a few more years (officially stated until 2022). You have a few years to test and migrate the old widget area section to the new interface.

2. Using manual code snippet

If you don’t want to use a plugin for this purpose, you can use a manual code snippet for this purpose.

  • Go to the Appearance > Theme Editor menu in your WordPress admin panel.
  • Paste the last code below.
/* Disable Widgets Block Editor */
add_filter( 'use_widgets_block_editor', '__return_false' );
  • Click “Update File” and save your changes.
  • Now go to Appearance > Widgets and you should see the old classic widget interface.
See also  How to bypass WP Rocket Caching in WordPress?

Keep in mind that it is recommended to use a child theme for the editor’s functions.php file so that your changes persist when you update the parent theme. Also, if “Theme Editor” is disabled in the admin panel, you can edit the file using FTP or the “File Management” application from your hosting account.

Which interface to use: old or new?

As mentioned, Gutenberg is the future of WordPress. While you can disable the old widget interface, we recommend that you fix the issues and plan to migrate to the new box widgets.

  • The new interface will display all legacy widgets without any customization options. You can remove these legacy widgets and replace them with the equivalent Gutenberg blocks.
  • Each block can be customized in the same way as editing them in the post or page editor. For example, you can easily customize the color and size of widget titles.
  • You can get the same editing experience throughout the site.

If your theme or plugin conflicts with the new widget editor interface, contact the developer and ask them to update the product. Otherwise, you may need to plan to migrate to the latest supported items.

Leave a Reply

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