Data-Driven Marketing
How to Plan and Analyse an A/B Test
Learn how to design, implement, and analyze A/B tests that provide statistically significant results for your marketing campaigns.
An A/B test compares versions of a marketing asset against a defined outcome. Plan the comparison before launch, then assess the size and uncertainty of the result. A well-run test will not always produce a statistically significant difference.
Understanding A/B Testing Fundamentals
A/B testing, also called split testing, compares two versions of a webpage, email or other marketing asset. Eligible participants are randomly assigned to a version during the same period. Compare the groups against a defined outcome, such as conversions, while checking that assignment and tracking worked as intended.
When to Use A/B Testing
A/B testing is most effective when:
- You have a specific hypothesis about how changes might improve conversions
- You have enough traffic to detect an effect of practical interest within the planned timeframe
- You're looking to make incremental improvements rather than radical changes
- You want concrete data to settle internal debates about design or copy
Setting Up a Proper A/B Test
1. Establish Clear Metrics
Before starting any test, define exactly what success looks like. Is it more sign-ups? Higher average order value? Increased time on page? Having a clear primary metric will keep your test focused.
2. Formulate a Strong Hypothesis
A good hypothesis follows this format: "If we [make this change], then [this metric] will [increase/decrease] because [rationale]." For example: "If we simplify the checkout form by removing non-essential fields, then conversion rate will increase because users will experience less friction."
3. Calculate Required Sample Size
Use a sample-size calculation based on the baseline rate, an effect worth detecting, the significance level and desired statistical power. An undersized test can miss a meaningful effect; a sample-size target does not guarantee a significant result.
Common A/B Testing Pitfalls to Avoid
Effective A/B testing requires avoiding several common mistakes:
- Testing too many elements at once: If several elements change together, the comparison measures their combined effect. It cannot isolate each element's contribution without an appropriate design.
- Stopping tests too early: Stopping a fixed-horizon test as soon as an interim result appears significant can increase false positives. Follow the stopping rule chosen for the analysis method.
- Ignoring seasonal factors: External events can skew results if not accounted for.
- Not controlling for device types: Changes might perform differently on mobile vs. desktop.
Analyzing Results Correctly
When your test concludes, proper analysis is crucial:
- Compare the result with the pre-specified significance level and examine an appropriate 95% confidence interval for the effect
- Check for consistent performance across segments (device types, new vs. returning visitors)
- Look for unexpected effects on secondary metrics
- Document learnings regardless of outcome
Building a Testing Culture
The most successful organizations make testing a continuous process rather than a one-off project. This involves:
- Creating a backlog of test ideas prioritized by potential impact and implementation ease
- Developing a regular testing cadence
- Sharing results across teams to build institutional knowledge
- Celebrating learning rather than just "winning" tests
Conclusion
Useful tests combine a clear hypothesis with a sound assignment and analysis plan. Report the observed effect and its uncertainty, including inconclusive results, and decide whether the change is worth implementing under the team's business constraints.
Read Google's description of randomized A/B tests, NIST's guidance on significance levels, and research on repeated monitoring and stopping rules for the assumptions behind these checks.