In this guide, you'll learn how to perform A/B testing between your Legacy CMS store and your Store Framework store. This test helps you determine which workspace delivers the highest conversion rate for your store.
The A/B test compares two versions of your store: the live Legacy CMS store in the master
workspace and the Store Framework store in the production
workspace, capable of receiving user traffic but not yet live.
Before you begin
- Install the VTEX IO CLI: The CLI allows you to log in to your VTEX account, manage workspaces, and develop new apps. For installation instructions, refer to the Installing VTEX IO CLI guide.
- Have a Store Framework theme ready: Ensure that you have a Store Framework theme ready for your store. If you haven't started building with Store Framework yet, follow the Storefront track for step-by-step guidance on creating your store from scratch.
- Verify your Edition App version: Confirm that your
development
workspace has thevtex.edition-store@5.x
Edition app installed by runningvtex edition get
in your terminal. If it's not installed, open a ticket with the VTEX support team to request its installation in the new Development workspace.
Instructions
Step 1 - Setting up the Legacy CMS
After creating your Store Framework theme and making changes in your development
workspace, set up the Legacy CMS environment to conduct the test. This setup allows you to evaluate your changes with real user traffic.
-
Create a production workspace to test your changes with some user traffic.
-
Run the
vtex use master
command in your terminal to perform the steps below in themaster
workspace. Themaster
workspace must be set to thevtex.edition-business@0.x
Edition app. -
Install the
vtex.colossus-legacy-proxy@@1.8.9-hkignore
app by running the following command. This app is responsible for routing requests within the VTEX IO environment during an A/B test between IO and Legacy CMS._10vtex install vtex.colossus-legacy-proxy@@1.8.9-hkignoreEnsure the app version is
1.8.9-hkignore
. Using a different version will prevent the store from responding correctly. Note that thevtex.colossus-legacy-proxy@1.8.9-hkignore
directs traffic to themaster
workspace in Legacy CMS Portal, while thevtex.colossus-legacy-proxy@2.x
version routes traffic to the VTEX IO workspace.
Step 2 - Requesting an A/B test
Now that you have set up the Legacy CMS environment for testing, you can request an A/B test. This step lets you compare the performance and user experience between your Legacy CMS environment and the VTEX IO environment, helping you make informed decisions about your store.
-
Open a ticket with the VTEX support team to request the redirection of the
production
workspace to be rendered in VTEX IO. Please provide the following information in your ticket:- Account name
production
workspace- Indicate whether the store features a distinct storefront for mobile devices.
-
Once the
production
workspace is ready, you can configure the A/B test as outlined in the Running native A/B tests guide.
Step 3 - Validating if the A/B test is running
To ensure the A/B test is active, send a GET
request to the following API: http://platform.io.vtex.com/{{accountName}}/_abtest/parameters
.
Include the
VtexIdclientAutCookie
header from the account you want to get the information. For example:VtexIdclientAutCookie: {{VtexIdclientAutCookie}}
The response should look something like this, indicating traffic distribution:
_10"master": {_10 "A": 9000,_10 "b": 1_10},_10"wsio": {_10 "A": 1000,_10 "b": 1_10}
This example shows that the master
is receiving 90% of the traffic, and the wsio
workspace is receiving 10%.
Step 4 - Migrating your changes
After completing the A/B test and deciding to migrate your store to Store Framework, open a ticket to the VTEX support team.