A/B testing explained

A/B testing (also known as bucket testing, split-run testing, or split testing) is a user experience research method.[1] A/B tests consist of a randomized experiment that usually involves two variants (A and B),[2] [3] [4] although the concept can be also extended to multiple variants of the same variable. It includes application of statistical hypothesis testing or "two-sample hypothesis testing" as used in the field of statistics. A/B testing is a way to compare multiple versions of a single variable, for example by testing a subject's response to variant A against variant B, and determining which of the variants is more effective.[5]

Overview

"A/B testing" is a shorthand for a simple randomized controlled experiment, in which a number of samples (e.g. A and B) of a single vector-variable are compared.[1] These values are similar except for one variation which might affect a user's behavior. A/B tests are widely considered the simplest form of controlled experiment, especially when they only involve two variants. However, by adding more variants to the test, its complexity grows.[6]

A/B tests are useful for understanding user engagement and satisfaction of online features like a new feature or product.[7] Large social media sites like LinkedIn, Facebook, and Instagram use A/B testing to make user experiences more successful and as a way to streamline their services.

Today, A/B tests are being used also for conducting complex experiments on subjects such as network effects when users are offline, how online services affect user actions, and how users influence one another. A/B testing is used by data engineers, marketers, designers, software engineers, and entrepreneurs, among others.[8] Many positions rely on the data from A/B tests, as they allow companies to understand growth, increase revenue, and optimize customer satisfaction.

Version A might be used at present (thus forming the control group), while version B is modified in some respect vs. A (thus forming the treatment group). For instance, on an e-commerce website the purchase funnel is typically a good candidate for A/B testing, since even marginal-decreases in drop-off rates can represent a significant gain in sales. Significant improvements can be sometimes seen through testing elements like copy text, layouts, images and colors,[9] but not always. In these tests, users only see one of two versions, since the goal is to discover which of the two versions is preferable.[10]

Multivariate testing or multinomial testing is similar to A/B testing, but may test more than two versions at the same time or use more controls. Simple A/B tests are not valid for observational, quasi-experimental or other non-experimental situations—commonplace with survey data, offline data, and other, more complex phenomena.

A/B testing is claimed by some to be a change in philosophy and business-strategy in certain niches, though the approach is identical to a between-subjects design, which is commonly used in a variety of research traditions.[11] [12] [13] A/B testing as a philosophy of web development brings the field into line with a broader movement toward evidence-based practice. The benefits of A/B testing are considered to be that it can be performed continuously on almost anything, especially since most marketing automation software now typically comes with the ability to run A/B tests on an ongoing basis.

Common test statistics

"Two-sample hypothesis tests" are appropriate for comparing the two samples where the samples are divided by the two control cases in the experiment. Z-tests are appropriate for comparing means under stringent conditions regarding normality and a known standard deviation. Student's t-tests are appropriate for comparing means under relaxed conditions when less is assumed. Welch's t test assumes the least and is therefore the most commonly used test in a two-sample hypothesis test where the mean of a metric is to be optimized. While the mean of the variable to be optimized is the most common choice of estimator, others are regularly used.

For a comparison of two binomial distributions such as a click-through rate one would use Fisher's exact test.

Assumed distribution Example case Standard test Alternative test
Average revenue per userWelch's t-test (Unpaired t-test) Student's t-test
Click-through rateBarnard's test
Transactions per paying user E-test[14] C-test
Number of each product purchased
Unknown

Challenges

When conducting A/B testing, the user should evaluate the pros and cons to see if it aligns well with the hoped-for results.

Pros: Through A/B testing, it is easy to get a clear idea of what users prefer, since it is directly testing one thing over the other. It is based on real user behavior, so the data can be very helpful especially when determining what works better between two options. In addition, it can also provide answers to very specific design questions. One example of this is Google's A/B testing with hyperlink colors. In order to optimize revenue, they tested dozens of different hyperlink hues to see which color the users tend to click more on.

Cons: As mentioned above, A/B testing is good for specific design questions but this can also be a downside since it is mostly only good for specific design problems with very measurable outcomes. It could also be a very costly and timely process. Depending on the size of the company and/or team, there could be a lot of meetings and discussions about what exactly to test and what the impact of the A/B test is. If there's not a significant impact, it could end up as a waste of time and resources.

In December 2018, representatives with experience in large-scale A/B testing from thirteen different organizations (Airbnb, Amazon, Booking.com, Facebook, Google, LinkedIn, Lyft, Microsoft, Netflix, Twitter, Uber, and Stanford University) attended a summit and summarized the top challenges in a SIGKDD Explorations paper.[15] The challenges can be grouped into four areas: Analysis, Engineering and Culture, Deviations from Traditional A/B tests, and Data quality.

History

It is difficult to definitively establish when A/B testing was first used. The first randomized double-blind trial, to assess the effectiveness of a homeopathic drug, occurred in 1835.[16] Experimentation with advertising campaigns, which has been compared to modern A/B testing, began in the early twentieth century.[17] The advertising pioneer Claude Hopkins used promotional coupons to test the effectiveness of his campaigns. However, this process, which Hopkins described in his Scientific Advertising, did not incorporate concepts such as statistical significance and the null hypothesis, which are used in statistical hypothesis testing.[18] Modern statistical methods for assessing the significance of sample data were developed separately in the same period. This work was done in 1908 by William Sealy Gosset when he altered the Z-test to create Student's t-test.[19] [20]

With the growth of the internet, new ways to sample populations have become available. Google engineers ran their first A/B test in the year 2000 in an attempt to determine what the optimum number of results to display on its search engine results page would be. The first test was unsuccessful due to glitches that resulted from slow loading times. Later A/B testing research would be more advanced, but the foundation and underlying principles generally remain the same, and in 2011, 11 years after Google's first test, Google ran over 7,000 different A/B tests.

In 2012, a Microsoft employee working on the search engine Microsoft Bing created an experiment to test different ways of displaying advertising headlines. Within hours, the alternative format produced a revenue increase of 12% with no impact on user-experience metrics. Today, companies like Microsoft and Google each conduct over 10,000 A/B tests annually.

Many companies now use the "designed experiment" approach to making marketing decisions, with the expectation that relevant sample results can improve positive conversion results. It is an increasingly common practice as the tools and expertise grow in this area.[21]

Examples

A company with a customer database of 2,000 people decides to create an email campaign with a discount code in order to generate sales through its website. It creates two versions of the email with different call to action (the part of the copy which encourages customers to do something — in the case of a sales campaign, make a purchase) and identifying promotional code.

All other elements of the emails' copy and layout are identical. The company then monitors which campaign has the higher success rate by analyzing the use of the promotional codes. The email using the code A1 has a 5% response rate (50 of the 1,000 people emailed used the code to buy a product), and the email using the code B1 has a 3% response rate (30 of the recipients used the code to buy a product). The company therefore determines that in this instance, the first Call To Action is more effective and will use it in future sales. A more nuanced approach would involve applying statistical testing to determine if the differences in response rates between A1 and B1 were statistically significant (that is, highly likely that the differences are real, repeatable, and not due to random chance).[22]

In the example above, the purpose of the test is to determine which is the more effective way to encourage customers to make a purchase. If, however, the aim of the test had been to see which email would generate the higher click-ratethat is, the number of people who actually click onto the website after receiving the emailthen the results might have been different.

For example, even though more of the customers receiving the code B1 accessed the website, because the Call To Action didn't state the end-date of the promotion many of them may feel no urgency to make an immediate purchase. Consequently, if the purpose of the test had been simply to see which email would bring more traffic to the website, then the email containing code B1 might well have been more successful. An A/B test should have a defined outcome that is measurable such as number of sales made, click-rate conversion, or number of people signing up/registering.[23]

A/B testing for product pricing

A/B testing can be used to determine the right price for the product, as this is perhaps one of the most difficult tasks when a new product or service is launched. A/B testing (especially valid for digital goods) is an excellent way to find out which price-point and offering maximize the total revenue.

Political A/B testing

A/B tests have also been used by political campaigns. In 2007, Barack Obama's presidential campaign used A/B testing as a way to garner online attraction and understand what voters wanted to see from the presidential candidate.[24] For example, Obama's team tested four distinct buttons on their website that led users to sign up for newsletters. Additionally, the team used six different accompanying images to draw in users. Through A/B testing, staffers were able to determine how to effectively draw in voters and garner additional interest.

HTTP Routing and API feature testing

A/B testing is very common when deploying a newer version of an API.[25] For real-time user experience testing, an HTTP Layer-7 Reverse proxy is configured in such a way that, N% of the HTTP traffic goes into the newer version of the backend instance, while the remaining 100-N% of HTTP traffic hits the (stable) older version of the backend HTTP application service. This is usually done for limiting the exposure of customers to a newer backend instance such that, if there is a bug on the newer version, only N% of the total user agents or clients get affected while others get routed to a stable backend, which is a common ingress control mechanism.

Segmentation and targeting

A/B tests most commonly apply the same variant (e.g., user interface element) with equal probability to all users. However, in some circumstances, responses to variants may be heterogeneous. That is, while a variant A might have a higher response rate overall, variant B may have an even higher response rate within a specific segment of the customer base.[26]

For instance, in the above example, the breakdown of the response rates by gender could have been:

Gender Overall Men Women
Total sends 2,000 1,000 1,000
Total responses 80 35 45
Variant A (5%) (2%) (8%)
Variant B (3%) (5%) (1%)

In this case, we can see that while variant A had a higher response rate overall, variant B actually had a higher response rate with men.

As a result, the company might select a segmented strategy as a result of the A/B test, sending variant B to men and variant A to women in the future. In this example, a segmented strategy would yield an increase in expected response rates from 5\% = \frac to 6.5\% = \frac – constituting a 30% increase.

If segmented results are expected from the A/B test, the test should be properly designed at the outset to be evenly distributed across key customer attributes, such as gender. That is, the test should both (a) contain a representative sample of men vs. women, and (b) assign men and women randomly to each “variant” (variant A vs. variant B). Failure to do so could lead to experiment bias and inaccurate conclusions to be drawn from the test.[27]

This segmentation and targeting approach can be further generalized to include multiple customer attributes rather than a single customer attributefor example, customers' age and genderto identify more nuanced patterns that may exist in the test results.

See also

Notes and References

  1. Young . Scott W. H. . August 2014 . Improving Library User Experience with A/B Testing: Principles and Process . Weave: Journal of Library User Experience . 1 . 1 . 10.3998/weave.12535642.0001.101 . free . free . 2027/spo.12535642.0001.101.
  2. Book: Kohavi . Ron . Trustworthy Online Controlled Experiments: A Practical Guide to A/B Testing . Xu . Ya . Tang . Diane . Cambridge University Press . 2000 . 22 October 2021 . 22 October 2021 . https://web.archive.org/web/20211022221504/https://experimentguide.com/ . live .
  3. Encyclopedia: 2023 . Online Controlled Experiments and A/B Tests . Encyclopedia of Machine Learning and Data Science . Springer . Kohavi . Ron . Phung . Dinh . 891–892 . 10.1007/978-1-4899-7502-7_891-2 . 978-1-4899-7502-7 . Longbotham . Roger . Webb . Geoff . Sammut . Claude . 21 April 2023 . 21 April 2023 . https://web.archive.org/web/20230421021311/https://exp-platform.com/encyclopediamldm/ . live .
  4. Kohavi . Ron . Thomke . Stefan . September-October 2017 . The Surprising Power of Online Experiments . Harvard Business Review . 74–82 . 27 January 2020 . 14 August 2021 . https://web.archive.org/web/20210814183956/https://hbr.org/2017/09/the-surprising-power-of-online-experiments . live .
  5. Web site: Hanington . Jenna . 12 July 2012 . The ABCs of A/B Testing . deviated . https://web.archive.org/web/20151224151946/http://www.pardot.com/blog/abcs-ab-testing/ . 2015-12-24 . 2016-02-21 . Pardot . en-US.
  6. Book: 10.1007/978-1-4899-7687-1_891 . Online Controlled Experiments and A/B Testing . Encyclopedia of Machine Learning and Data Mining . 2017 . Kohavi . Ron . Longbotham . Roger . 922–929 . 978-1-4899-7685-7 .
  7. Book: Xu . Ya . Chen . Nanyu . Fernandez . Addrian . Sinno . Omar . Bhasin . Anmol . Proceedings of the 21st ACM SIGKDD International Conference on Knowledge Discovery and Data Mining . From Infrastructure to Culture: A/B Testing Challenges in Large Scale Social Networks . 10 August 2015 . 2227–2236 . 10.1145/2783258.2788602 . 9781450336642 . 15847833 .
  8. Book: Siroker . Dan . A / B Testing: The Most Powerful Way to Turn Clicks Into Customers . Koomen . Pete . 2013-08-07 . John Wiley & Sons . 978-1-118-65920-5 . 15 October 2020 . 17 August 2021 . https://web.archive.org/web/20210817043106/https://books.google.com/books?id=VfVvAAAAQBAJ&q=A/B%20Testing&pg=PT13 . live .
  9. Web site: Split Testing Guide for Online Stores. August 27, 2012. webics.com.au. 2012-08-28. 3 March 2021. https://web.archive.org/web/20210303181237/https://www.webics.com.au/blog/google-adwords/split-testing-guide-for-online-retailers/. live.
  10. Kaufman . Emilie . Olivier . Cappé . Aurélien . Garivier . 2014 . On the Complexity of A/B Testing . 35 . 461–481 . Proceedings of The 27th Conference on Learning Theory . 2014arXiv1405.3224K . 1405.3224 . 27 February 2020 . 7 July 2021 . https://web.archive.org/web/20210707144220/http://proceedings.mlr.press/v35/kaufmann14.pdf . live .
  11. Web site: The A/B Test: Inside the Technology That's Changing the Rules of Business. Wired Business. Christian. Brian. 2000-02-27. 2014-03-18. 17 March 2014. https://web.archive.org/web/20140317101247/http://www.wired.com/business/2012/04/ff_abtesting. live.
  12. Test Everything: Notes on the A/B Revolution | Wired Enterprise. Christian. Brian. Wired. 2014-03-18. 16 March 2014. https://web.archive.org/web/20140316061405/http://www.wired.com/wiredenterprise/2012/05/test-everything. live.
  13. Web site: A/B testing: the secret engine of creation and refinement for the 21st century. Cory Doctorow. 2012-04-26. Boing Boing. 2014-03-18. 9 February 2014. https://web.archive.org/web/20140209001259/http://boingboing.net/2012/04/26/ab-testing-the-secret-engine.html. live.
  14. 10.1016/S0378-3758(02)00408-1. A more powerful test for comparing two Poisson means. Journal of Statistical Planning and Inference. 119. 23–35. 2004. Krishnamoorthy. K.. Thomson. Jessica. 26753532.
  15. Somit . Gupta . Ronny . Kohavi . Diane . Tang . Ya . Xu . Reid . Andersen . Eytan . Bakshy . Niall . Cardin . Sumitha . Chandran . Nanyu . Chen . Dominic . Coey . Mike . Curtis . Alex . Deng . Weitao . Duan . Peter . Forbes . Brian . Frasca . Tommy . Guy . Guido W. . Imbens . Guillaume . Saint Jacques . Pranav . Kantawala . Ilya . Katsev . Moshe . Katzwer . Mikael . Konutgan . Elena . Kunakova . Minyong . Lee . MJ . Lee . Joseph . Liu . James . McQueen . Amir . Najmi . Brent . Smith . Vivek . Trehan . Lukas . Vermeer . Toby . Walker . Jeffrey . Wong . Igor . Yashkov . June 2019 . Top Challenges from the first Practical Online Controlled Experiments Summit . SIGKDD Explorations . 21 . 1 . 20–35 . 10.1145/3331651.3331655 . 153314606 . 24 October 2021 . 13 October 2021 . https://web.archive.org/web/20211013165632/https://exp-platform.com/top-challenges-from-first-practical-online-controlled-experiments-summit/ . live.
  16. Stolberg . M . Inventing the randomized double-blind trial: the Nuremberg salt test of 1835 . Journal of the Royal Society of Medicine . December 2006 . 99 . 12 . 642–643 . 10.1177/014107680609901216 . 17139070 . 1676327 .
  17. Web site: What is A/B Testing . Convertize . 2020-01-28 . 17 August 2020 . https://web.archive.org/web/20200817215345/https://www.convertize.com/what-is-ab-testing/ . live .
  18. Web site: Claude Hopkins Turned Advertising Into A Science . 2019-11-01 . . 20 December 2018 . 10 August 2021 . https://web.archive.org/web/20210810111651/https://www.investors.com/news/management/leaders-and-success/claude-hopkins-scientific-advertising-bio/ . live .
  19. Web site: How beer influenced statistics . 20 June 2007 . Ron . Pereira . Gemba Academy . Blog . 22 July 2014 . 5 January 2015 . https://web.archive.org/web/20150105221541/http://blog.gembaacademy.com/2007/06/20/how-beer-influenced-statistics/ . live .
  20. Box . Joan Fisher . Guinness, Gosset, Fisher, and Small Samples . Statistical Science . 1987 . 2 . 1 . 45–52 . 10.1214/ss/1177013437 . free .
  21. Web site: 2020-01-17 . A/B Testing: The ABCs of Paid Social Media . 2022-04-08 . . en-US . 31 March 2022 . https://web.archive.org/web/20220331132522/https://anyword.com/blog/a-b-testing-paid-social-media/ . live .
  22. Web site: developer.amazon.com . The Math Behind A/B Testing . 2015-04-12 . dead . https://web.archive.org/web/20150921174256/https://developer.amazon.com/public/apis/manage/ab-testing/doc/math-behind-ab-testing . 2015-09-21 .
  23. Kohavi . Ron . Longbotham . Roger . Sommerfield . Dan . Henne . Randal M. . Controlled experiments on the web: survey and practical guide . Data Mining and Knowledge Discovery . February 2009 . 18 . 1 . 140–181 . 10.1007/s10618-008-0114-1 . 17165746 . free .
  24. Book: Siroker. Dan. A / B Testing: The Most Powerful Way to Turn Clicks Into Customers. Koomen. Pete. 2013-08-07. John Wiley & Sons. 978-1-118-65920-5. 15 October 2020. 17 August 2021. https://web.archive.org/web/20210817043106/https://books.google.com/books?id=VfVvAAAAQBAJ&q=A/B%20Testing&pg=PT13. live.
  25. LISA 2018. Modern HTTP Routing. Sandor. Szucs. 2018. Usenix.org. 1 September 2021. 1 September 2021. https://web.archive.org/web/20210901185744/https://www.usenix.org/sites/default/files/conference/protected-files/lisa18_slides_szucs.pdf. live.
  26. Web site: Advanced A/B Testing Tactics That You Should Know | Testing & Usability. Online-behavior.com. 2014-03-18. 2014-03-19. https://web.archive.org/web/20140319000032/http://online-behavior.com/testing/advanced-ab-testing-tactics-1356. dead.
  27. Web site: Eight Ways You've Misconfigured Your A/B Test. 2013-09-12. Dr. Jason Davis. 2014-03-18. 18 March 2014. https://web.archive.org/web/20140318224917/http://drjasondavis.com/2013/09/12/eight-ways-youve-misconfigured-your-ab-test/. live.