Product Mastery / Growth & Experiments

A/B Testing

Run online controlled experiments you can trust, from a falsifiable hypothesis to a readout that survives a sceptical review.

Getting numbers is easy; getting numbers you can trust is hard.
— Ron Kohavi, Diane Tang and Ya Xu, Trustworthy Online Controlled Experiments

An A/B test randomly splits users between the current experience and one or more changes, then compares how each group behaves. Randomisation is the whole trick. Because chance decides who sees what, the change is the only systematic difference between the groups, and a gap in the metric can be read as cause rather than correlation. That makes controlled experiments the strongest evidence a product team can collect about what a change actually does. Ronny Kohavi, who led experimentation at Amazon, Microsoft and Airbnb, has shown repeatedly that most ideas fail to improve the metric they were aimed at, which is why gut feel and stakeholder confidence make poor substitutes.

The hard part is trustworthiness. A good test starts with a falsifiable hypothesis, a sensible randomisation unit, one primary metric and a set of guardrails, plus a sample size calculated from the minimum effect worth shipping. It then has to survive the classic failure modes. Peeking and stopping early inflates false positives, a sample ratio mismatch means the split itself is broken, novelty and primacy effects distort short tests, and slicing twenty metrics guarantees a lucky winner. Knowing what a p-value means, when variance reduction such as CUPED helps, and when an A/B test is the wrong tool altogether is what separates a data-informed PM from one who ships noise with a confidence interval attached.

Visual Guide

Infographic coming soon

Audio Deep Dive

Audio deep dive coming soon

How to Leverage AI for A/B Testing

AI is a useful sparring partner for experiment design and a tireless reviewer of readouts. Treat its arithmetic as a first draft and its scepticism as the real value.

Provide Context to the AI

A. The "Numbers" Inputs

  • •Baselines and variance: The current value of the primary metric, plus its standard deviation for continuous metrics such as revenue per user. Without variance, any sample size estimate is a guess.
  • •Traffic and allocation: Weekly eligible users for the surface being tested, the planned split, and how many variants you want to run.
  • •Aggregate results: For a readout review, the variant counts, deltas, confidence intervals, p-values and the daily trend. Summary tables are enough.

B. The "Decision" Context

  • •Hypothesis and history: Why you believe the change will work, plus past experiments on the same surface and how big their effects were. Past effect sizes are the best anchor for a realistic MDE.
  • •Cost of being wrong: How reversible the decision is and which guardrails the business will not trade away, such as latency, revenue or unsubscribes.

C. The "Anti-Context" (What Not to Do)

  • •No user-level raw data: Do not paste row-level logs with identifiers into a chat tool. Aggregates answer every question on this page.
  • •No fishing: Never ask the AI to "find a metric or segment where the treatment won". That is p-hacking with extra steps.
  • •No blind trust in its maths: Language models make arithmetic slips. Confirm any final sample size with a dedicated calculator or your experimentation platform.

Tip: Paste the aggregate numbers into the prompt and state your decision rule before you ask about results.

1. Experiment Plan (Before Launch)

Goal: Turn a feature idea into a falsifiable, pre-registered test design.

Prompt:

"Act as a senior experimentation lead who has reviewed hundreds of A/B tests. Help me write an experiment plan for [CHANGE] on [PRODUCT / SURFACE]. Context: our users are [SEGMENT], the business goal is [GOAL], and my rough idea of why this should work is [INSIGHT]. Produce: (1) a falsifiable hypothesis in the form 'Because [insight], we believe [change] will move [metric] by at least [MDE] for [segment]'; (2) the randomisation unit, with a sentence on why, and any risk of interference between users; (3) one primary metric and why it reflects long-term value; (4) 3 to 5 guardrail metrics, including at least one trust check such as sample ratio mismatch; (5) the decision rule written before launch: what result makes us ship, iterate or kill. Challenge any part of my idea that cannot be falsified. Ask me one clarifying question at a time if information is missing."

2. Sample Size and Run Time Assumptions

Goal: Make the power, MDE and traffic assumptions explicit before anyone commits to a launch date.

Prompt:

"Act as a statistician helping a product manager size an A/B test. Our primary metric is [METRIC]. Baseline: [BASELINE RATE, e.g. 4.2% conversion] or, for a continuous metric, mean [MEAN] and standard deviation [SD]. We get about [N] eligible users per week, split [SPLIT, e.g. 50/50] across [NUMBER] variants. The smallest effect worth shipping is [MDE, relative or absolute]. Assume a two-sided test with alpha [0.05] and power [0.8] unless I say otherwise. (1) Estimate the users needed per variant, showing the formula and each assumption. (2) Convert that into a run time in whole weeks. (3) Show how the run time changes if the MDE is halved or doubled. (4) Flag any assumption likely to be wrong, such as variance being higher for revenue metrics or users being randomised at a different unit from the analysis. (5) If the run time is over [MAX WEEKS], tell me plainly whether to test something bolder, use variance reduction such as CUPED, or skip the A/B test. I will confirm the final number with a dedicated calculator."

3. Results Readout Sanity Check

Goal: Catch the common errors before a result reaches a launch review.

The "Twyman" Review:

"Act as a sceptical reviewer of A/B test results, applying Twyman's law. Any result that looks surprising is probably wrong until proven otherwise. Here is the readout: [PASTE RESULTS: variant counts, metrics, deltas, confidence intervals, p-values, run dates, how and when the decision was made]. Check for: (1) sample ratio mismatch, by running a chi-square test on the assignment counts against the planned split; (2) peeking, meaning the test was stopped early or the stop date moved after seeing results; (3) multiple comparisons, where many metrics or segments were examined and only the winners reported; (4) novelty or primacy effects visible in the daily trend; (5) a mismatch between randomisation unit and analysis unit; (6) statistical significance being treated as practical significance; (7) any guardrail that moved the wrong way. For each issue, say how serious it is and what extra analysis would settle it. End with a verdict: trustworthy, needs more work, or not decision-grade."

4. Should We Even A/B Test This?

Low traffic, one-way doors and long-horizon outcomes all weaken a standard test. Use this prompt to pick the right evidence for the decision.

Prompt:

"Act as a pragmatic product leader who respects experimentation but knows its limits. I am considering an A/B test for [DECISION]. Facts: weekly eligible traffic is [N], the expected effect is [SIZE], the outcome we care about plays out over [TIME HORIZON], and reversing the decision after launch would cost [REVERSIBILITY / COST]. Tell me whether a standard A/B test is the right tool. If not, recommend the best alternative from options such as a longer holdout, a quasi-experiment, a staged rollout with monitoring, qualitative research, or a reasoned judgement call, and explain what evidence each would give me and what it would miss."

Test Your Knowledge

Take this quiz to test your understanding of experiment design and the statistics behind A/B testing.

Question 1 of 80 answered

Your readout shows p = 0.03 for the lift in conversion. Which interpretation is correct?

Flashcards

Review key concepts with these flashcards. Click on a card to reveal the answer.

Card 1 of 38
QUESTION

What is an online controlled experiment (A/B test)?

Click to reveal answer
ANSWER

Users are randomly assigned to a control or one or more treatments, and the metrics of each group are compared. Randomisation lets you attribute a difference to the change itself.

Click to see question