Pushing your AB Tasty variants into Zuko

AB Tasty is a powerful A/B testing and experimentation platform, allowing its users to optimize their website performance. Using this guide, you can push through your form test variants into Zuko through the use of Custom Attributes to compare and analyse the performance data. 

Please note that this guide assumes that you have already applied Zuko’s activity tracking and completion tags to your form. 

If not, this is the first step you should take. The guides here will help you add your form to Zuko and then add the tracking codes to it:

Adding a form in Zuko

Adding tracking codes to your site

Using Zuko’s data layer to push through your test variants

In order to push the variants into Zuko, you can use Zuko’s attributes data layer- by using the data layer, the variants you have set in ABTasty will be picked up while the visitor is on your form and this will be added as an attribute to their session in Zuko. 

In order to do this:

  1. Open your GTM container and add a new tag. 
  2. Select Custom HTML, and then copy and paste in the below code- note that this code should be kept separate from your Zuko tracking tag. 

<script>

if (ABTasty) {

  const tests = ABTasty.getTestsOnPage();

  if (Object.values(tests).length) {

    window.zuko = window.zuko || {};

    window.zuko.attributes = window.zuko.attributes || {};

    for (const [key, test] of Object.entries(tests)) {

      window.zuko.attributes[`ABTasty Test ${key}`] = `Variation ${test.variationID}`;

    }

  }

}

</script>

  1. Your trigger should be the same as the trigger you are using for your Zuko activity tracking tag so that both the tracking and attribute tags are fired at the same time. In most cases, a Page View- Window Loaded trigger is appropriate. 
  2. It is good practice to use Preview mode in GTM before publishing, to make sure that there are no errors in the code, and the tag is triggered when we expect. 
  3. Once you’re happy that the tag is being fired as expected, Publish the tag. 

Once you have completed the setup and there is an ABTasty test running on your form, this will appear as a Custom Attribute that is accessible from the Select A Filter dropdown in your Zuko reports: 

The attributes will have a Key of 'ABTasty Test [ABTasty Test ID]' and a value of 'Variation: [ABTasty variationId]'

You will then be able to analyse each variation by filtering the data in your Zuko reports, and compare the form and field data by using Form Segment Comparison and Field Segment Comparison in your Segments tab. 

See more guides
zuko full colour logo
Formisimo Ltd, Colony, 5 Piccadilly Place, Manchester, M1 3BR
VAT Number: GB181252425
Registered in England as company number 08859680
New Business: sales@zuko.io
Support: support@zuko.io