A/B tests
Comparing two versions with real users to see which performs better.
An A/B test shows each version to a random group and compares a metric. It is the most reliable way to measure the effect of a product change, given enough traffic. With low traffic, other methods often teach more.
Why it matters for a product engineer
Most product ideas do less than their authors expect, and a few do much more. An A/B test measures the real effect of a change by showing each version to a random group of users. Engineers build the assignment, the flags and the events, so the quality of the test depends on them as much as on the analysis.
How to do it
- Write the hypothesis, the main metric, the guardrails and the decision rule before you start.
- Work out how many users you need, and so how long the test must run.
- Assign users at random and keep each one in the same group for the whole test.
- Check that the groups have the expected sizes before reading any result. A mismatch usually means a bug.
- Do not stop the test early because the result looks good. Wait for the planned sample.
- Record the result and the decision, including tests that showed nothing.
Common mistakes
- Looking at the results every day and stopping at the first good one.
- Testing with too little traffic to see any realistic effect.
- Changing the test while it runs.
- Many metrics with no main one, so something always looks like a win.
- Only testing big ideas, and never the small ones that might matter more.
Example
In 2012 a Microsoft employee suggested changing how Bing displayed ad headlines. It would take a few days of work, but it was one of hundreds of ideas and stayed on the list for more than six months. When an engineer finally ran an A/B test, the new version made so much money that an alert fired, which usually means a bug. It was not a bug: revenue rose 12%, without hurting user experience.
The Bing headline test
- 6+months
- On the list as a low priority
- 12%
- More revenue
- $100M+
- A year, in the US alone
The best revenue idea in Bing's history looked minor to everyone until it was tested.
ReportedRon Kohavi and Stefan Thomke, Harvard Business Review, Sep–Oct 2017
Sources: The surprising power of online experiments (Ron Kohavi and Stefan Thomke, Harvard Business Review) ↗ · How not to run an A/B test (Evan Miller) ↗
AI leverage
Use AI in your workUse AI to support this skill. Your judgment and verification remain part of the work.
- Workflow
- Draft alternative treatments and review an experiment plan for missing assumptions before implementation.
- Limitations
- AI can invent statistical certainty or encourage stopping at a favorable result.
- Verification
- Predefine the analysis, verify random assignment and check sample ratios and guardrails before interpreting lift.
Technical leverage
Implement assignment, exposure logging and reproducible analysis so the treatment can be connected to its outcome.
Evidence of mastery
Put it into practice- Practice
- Run a controlled experiment with a primary metric and a stopping rule.
- Artifact
- An experiment record with estimates, uncertainty and a decision, including inconclusive results.
What good looks like
- Assignment and exposure are validated.
- The conclusion respects the planned analysis and observed uncertainty.
Use this evidence to assess your work. Your map status is a self-assessment, not a certification.
In practice
Real products- 11 Nov 2026Etengabe: the first session
Resources
2- articleStart here
How not to run an A/B test ↗
Evan Miller · 2010 · 8 minThe classic explanation of why peeking at results and stopping early produces false wins, and what to do instead.
- bookGo deeper · Paid
Trustworthy online controlled experiments: a practical guide to A/B testing ↗
Ron Kohavi, Diane Tang, Ya Xu · 2020 · 288 pagesThe standard reference on running experiments at scale, written by the people who built experimentation at Microsoft, Google and LinkedIn.
Tools
3- ToolOpen source
GrowthBook
Open-source feature flags and A/B testing that analyzes results from your own data warehouse.
- ToolFreemium
Statsig
Feature flags, experiments and product analytics with built-in statistics such as variance reduction.
- ToolOpen source
PostHog
Open-source product analytics with session replay, feature flags, experiments and surveys in one tool.