LiftIgniter’s Single Item A|B Testing feature will allow you to automatically test between multiple titles, images, or other metadata specified in an item’s inventory.  


In the instructions below, we’ll use "title" and "altTitle" as the example fields, but this can be done with any item inventory field you choose.


1. Test Set Up

To start a test, you’ll need to add multiple titles (or image URLs, descriptions, or other metadata you want to test) to the item. We recommend keeping the original "title" field as the default title, so that the article can be displayed with the original title anywhere you do not want to run the test.

  1. Add a new field to contain both the control and test candidates (e.g. "altTitle") using the LiftIgniter JSON object if you are using our JS integration to update inventory, or via the /inventory endpoint if you are using our API.

  2. Add a field called "abnFields". This will designate which fields we are testing.


Sample JSON

{
  "title": "My Original Title",
  "altTitle": ["My Original Title", "Test Title 1", "Test Title 2", "Test Title 3"],
  "abnFields": ["altTitle"]
}



2. Test Implementation

Testing will automatically start once the “abnFields” parameter has a value. Our system will detect the number of candidates, and ensure that each variant is returned in an even ratio (two candidates will get a 50/50 split, four candidates will be shown to 25% of traffic each, etc).


To get the selected test value back in our JSON response, you will need to modify your widget implementation to request that the new “altTitle” field be returned. This can be done by using $p(“setRequestFields”) in the JS to include “altTitle”, or via the “requestFields” parameter in the widget opts. You'll also need to update the template to use "altTitle" instead of the original "title" field.


3. Identify the Winner

Test variant reporting can be obtained via our Analytics endpoint. Please contact Support if you have any questions!


4. End a Test 

To end a test, you can either clear the “altTitle” field of all variants, clear the “abnFields” parameter, or remove “abnFields” from the item entirely. 


FAQ

1. If abnFields is empty and I request the altTitle field, what value will I get back?

Only the first value in the altTitle array will be returned. As a result, we recommend always placing the original “title” or the expected default first in the array.


2. Can I test more than just titles?

Yes! The abnFields parameter will accept any fields. You can test titles, images, text snippets, or any other aspect of the item display. Here’s an example including both a title and image test.

{
  "title": "My Original Title",
  "image": "www.originalurl.com/image.png",
  "altTitle": ["My Original Title", "Test Title 1", "Test Title 2", "Test Title 3"],
  "altImage": ["www.originalurl.com/image.png", "www.testimage.com/image1.png", "www.testimage.com/image2.png", "www.testimage.com/image3.png", "www.testimage.com/image4.png"],
  "abnFields": ["altTitle", "altImage"]
}


3. Are specific field names required?

“abnFields” is the required name for the parameter to tell us which fields contain test candidates. The candidate fields themselves can be called any name.