Want to conduct A/B tests on your WordPress site? You can use Google Optimize to conduct experiments to see what works best on your site. With MonsterInsights, you can easily connect Google Optimize with Google Analytics.
Before we begin, you’ll need to have the MonsterInsights Google Optimize addon installed, which is available to Pro level users. Once you’ve purchased or upgraded to a Pro license, you will need to install the Google Optimize addon.
Step 1: Create a New Google Optimize Account
First, create a new Google Optimize account by going to optimize.google.com. Then, click Get Started.
Now you’ll have to enter an Account name, opt into sharing data (if desired), and accept terms of service for your country.
You may use your own name or your company name. (e.g. MonsterInsights) for your Account name.
Click Next and you’ll be prompted to enter a Container name. You may use the domain name of your site. (e.g. MonsterInsights.com)
An account allows you to run experiments on one or more domains you own. You’ll likely need only one account. The container is where all your experiments and configuration settings will live.
Once you’ve inputted a Container name, click Create.
Step 2: Create An Experience
Now you’ll create your first experience in your newly created container. Click on Let’s go.
The sidebar will expand, and you’ll need to:
- Name your experience.
- Identify the website URL.
- Choose your experience type.
Once you’ve decided on a name, URL and experience, click Create.
Step 3: Link Your Optimize Account to Google Analytics
After you create your experience, you’ll be taken to the details page of that experience.
To link your Optimize account to your Google Analytics account, scroll down to the Measurement and objectives section. Click on Link to Analytics.
Now select the Google Analytics property from the dropdown that corresponds to the site on which you’ll be running experiments.
Once you’ve chosen your Analytics property (and view, if prompted), you can click Link.
Step 4: Add Optimizer to Your Website
Now return to the overview page of your container and click on Settings.
You’ll be able to find an Optimize Container ID. This should be in the format of OPT-XXXXXXX or GTM-XXXXXXX. Copy this ID.
Then, log in to your WordPress dashboard, and navigate to Insights » Settings » Conversions.
Input your container ID in the Google Optimize Container ID field.
You can also click the checkbox near Enable Google Optimize Async Page Hide Compatibility. It reduces the risk of page flickering (the original page appears briefly before loading the variation). It also ensures that users with slow connections have a better experience by only showing experiment variants when the Optimize container loads within the set timeout.
Lastly, if you only want to load your Optimize Container ID on specific pages, you can configure the option Load Container Conditionally.
Once done, click Save Changes.
Step 5: Start An Experience

That’s it!
You’ve successfully set up Google Optimize in WordPress.
If you enjoyed this article, you might also want to read how to stay within the free processing limit of Google Analytics.