Enable Divi Builder by Default on New Posts / Pages

The Divi Theme gives you the option of using the Divi Builder drag and drop editor on your posts and pages. This is normally something you have to explicitly enable by clicking on the "Use Divi Builder" button on every single post / page you start. Wouldn't it be great if you could have the Divi Builder automatically enabled on your new posts and pages? Here's how to do it.

Enable the Front-End Visual Builder by Default using Divi Booster

Divi Booster includes an option to make front-end visual Divi Builder the default editor. You'll find it on the Divi Booster settings page, at:

Divi Builder > General > Enable Divi Builder by default on new pages / posts

Simply check the box to enable the option, and then save your changes. The Divi Builder should now automatically be enabled on new posts and pages.

Custom Post Types

The feature also works on Custom Post Types. However, you may need to enable the Divi Builder on your Custom Post Type in the Divi Theme Options at:

Divi > Theme Options > Builder > Post Type Integration > Enabler Divi Builder on Post Types

Supported Version

The option is available in Divi Booster from version 2.5.9 onwards. Early versions of the feature only supported the classic editor, but since version 3.2.2 the feature also works with the WordPress block editor (aka "Gutenberg").

Enable the Back-End Visual Builder by Default

Divi includes a built-in way to enable the back-end version of the Divi Builder by default.

To do so, we must disable the WordPress block editor, which can be done by disabling this option:

Divi > Theme Options > Builder > Advanced > Enable Classic Editor

This will restore the old and largely unsupported "Classic" version of the Divi Builder. To enable the "Latest Divi Builder Experience" instead (i.e. the same version of the builder that you get on the front-end), enable this option:

Divi > Theme Options > Builder > Advanced > Enable The Latest Divi Builder Experience 

Enabling the Divi Builder using PHP

If you're comfortable adding PHP code to Divi, you can use the following code to set the Divi Builder as the default editor on new posts:
add_action('load-post-new.php', 'dbc_load_post_new_php'); 

function dbc_load_post_new_php() { 
	add_filter('et_builder_always_enabled', '__return_true');
}; 

This post may contain referral links which may earn a commission for this site

Divi Booster

Hundreds of new features for Divi
in one easy-to-use plugin

6 Comments

  1. Hi Dan, I've enabled this in Divi Booster but it is opening new pages/posts into the Front End builder. Is there any way to get it to open into the Classic Builder instead?

    Thank you.

    Reply
    • Hey Dave, yes, you can enable the Classic Builder using options within Divi itself. I've just added a "Enable the Back-End Visual Builder by Default" section to the post that explains how. Note that you should disable the Divi Booster option if you're using this approach. I hope that helps!

      Reply
      • Ah I see. I didn't know about that setting. Thanks!

        Reply
        • You’re welcome, Dave!

          Reply
  2. What is the PHP code for determining which pages/posts currently use the Divi Builder?

    What is the PHP code for un-doing et_builder_always_enabled, to set "Always Use Gutenberg Editor" for new pages/posts?

    Reply
    • Hey George,

      1) you should be able retrieve the posts / pages currently using the Divi Builder with the following:

      $builder_posts = get_posts( array(
        'meta_key'   => '_et_pb_use_builder',
        'meta_value' => 'on',
      ));
      

      This will return an array of WP_Post objects of those pages / posts using Divi Builder.

      2) You can override the et_builder_always_enabled setting with this:

      add_filter('et_builder_always_enabled', '__return_false', 9999);

      You need to make sure the "priority" is set such that it comes after any other filter which is setting it to true. Here I've set the priority to 9999 which will probably be plenty in most cases (a larger number = value is set later).

      I haven't played around with it enough to know if that's enough by itself to achieve the desired "Always Use Gutenberg Editor" setting. If not, let me know and I'll dig into it some more. Thanks!

      Reply

Submit a Comment

Your email address will not be published.