Page builder

A/B testing for Gutenberg

Run cookieless, flicker-free split tests on your Gutenberg pages - free, with no traffic limits and no third-party tracking. With the native WordPress block editor there's nothing extra to install - every block already has a field for a CSS class.

Why it fits Gutenberg

  • No lock-in

    AB Test WP matches variants by a CSS class, so it works inside Gutenberg without replacing your editor or markup.

  • Fast & flicker-free

    The original never flashes - the tested element stays hidden until the assigned variant is applied - and assignment runs in the browser, so Gutenberg pages stay fast and cache-friendly.

  • Private by default

    No cookies and no third-party calls in the page your visitors load. Their data stays in your own WordPress database.

Setup

Adding a test class in Gutenberg

Each variant gets a class from the plugin. Add it to the matching element in Gutenberg - that's the only builder-specific step.

  1. Create the test

    In the AB Test WP dashboard, create a test. It generates a class for each variant, for example:.abtest-hero-cta-v1

  2. Add the class in Gutenberg

    Select the block → Settings sidebar → AdvancedAdditional CSS class(es). Use the class that matches the version you are editing: the one ending in -default on the original, the one ending in -v1 on the new version.

  3. Pick a goal & launch

    Choose a conversion goal - a page visit, an element click, a link click, a form submission or a WooCommerce add-to-cart - then start the test and watch results come in.

The New A/B test screen: test name with the generated CSS class, the element versus full-page choice, then variants, conversion goal and advanced steps
Step 1 in the plugin: naming the test generates the CSS classes you paste into Gutenberg.

Verified against the WordPress block editor in September 2026. Builders change their panels between major versions, so this page names the version it was checked against. Source: WordPress documentation: the WordPress editor.

What you can test on a Gutenberg site

Anything you can give a CSS class: headlines, calls to action, hero images, pricing tables, section order, or whole landing pages via a URL/redirect test. Free covers two-variant tests with up to three running at once; Pro adds up to six variants, advanced goals, WooCommerce revenue, and statistical significance.

Using a different tool as well? AB Test WP works the same way in every major builder - one plugin across every site you build.

How it works

One Gutenberg page, two variants

No second page to maintain, no redirect, and the same cached HTML for every visitor. Here is the whole mechanism.

  1. Both versions ship in one page

    You build both versions in Gutenberg and give each one the class the plugin generated: the original gets the class ending in -default, the new version the one ending in -v1. Both sit in the same page.

    abtest-hero-cta-default abtest-hero-cta-v1

  2. The browser picks a side

    A visitor arrives on the cached page. Both versions start hidden, then the plugin's script assigns the visitor a variant in the browser and reveals only that one, so the original never flashes and no cookie is set.

    50% see A50% see B

  3. The count lands in your database

    Impressions and conversions are written to your own WordPress tables. Nothing leaves the site, and the CDN keeps serving the same cached HTML to everyone.

    your site → your database

FAQ

Gutenberg questions

The things people ask before their first Gutenberg test.

Where is the CSS class field in Gutenberg?

Select the block -> Settings sidebar -> Advanced -> Additional CSS class(es). Use the class that matches the version you are editing: the one ending in -default on the original, the one ending in -v1 on the new version.

Can I test a whole Gutenberg page or template?

Yes. Build the second version as its own page and run a URL split test: the redirect happens in the page head before anything paints, each visitor stays on the version they first saw, and the variant's canonical points at the original by default.

Do I have to use the class field, or does point-and-click work on Gutenberg pages?

Both work. Point-and-click runs on the front end of any page while you are logged in with the admin bar showing, so you can click a headline, button or paragraph that Gutenberg rendered and type the alternative without opening the editor. The class field is there when you would rather build the variant in Gutenberg.

Does the class field exist on every block?

Every core block has the Additional CSS class(es) field under Advanced, and most third-party block libraries keep it, so nothing extra is needed.

Start testing your Gutenberg pages

The free plugin is in final testing. Join the waitlist and we will email you the day it lands.