null hypothesis (H0)
The default claim of no difference or no effect, e.g. 'the new checkout does not change conversion'.
Every statistical test starts with two competing claims. The null hypothesis is the boring default: there is no difference, no effect, nothing going on. The alternative hypothesis is the claim you would like to support: there is a difference. In an A/B test on conversion:
Why start from "nothing happened"? Because it is the only claim precise enough to calculate with. Assuming is true, we can work out how much the results would wobble from sampling noise alone, and then ask how surprising our actual data would be in that world. That surprise is the p-value. If (usually 0.05), the data are hard to square with , and we reject it in favour of . If not, we fail to reject .
The wording matters. Failing to reject does not prove there is no effect; it means this test, with this sample, did not find convincing evidence. Think of a court: "not guilty" is not the same as "innocent". Likewise, rejecting says an effect is probably not zero, not that it is large or worth shipping; that is a question of effect size and practical significance.
The alternative can be two-sided ("B differs from A", the safe default) or one-sided ("B is better than A"). Choose it, along with and the primary metric, before you look at the results. Picking the direction after seeing the data quietly doubles your chance of a false positive, the type I error.
Example
CatChow tests a checkout redesign: 1,000 users see the old checkout (A), 1,000 see the new one (B).
Hypotheses, written before launch:
- : the redesign doesn't change conversion,
- : it does change conversion, (two-sided, )
Results: A converts 52 of 1,000 (5.2%), B converts 68 of 1,000 (6.8%). The difference is 1.6 percentage points.
Test under . If there were truly no difference, both groups would share one conversion rate, estimated by pooling: . The standard error of the difference is
so . The two-tailed p-value is about 0.13.
Decision. , so we fail to reject . The correct summary is not "the redesign doesn't work" but "a 1.6 pp gap this size shows up about 13% of the time from noise alone, so 1,000 users per group can't tell us yet". The 95% confidence interval for the difference, about −0.5 to +3.7 pp, still includes zero and also includes a meaningful win. The next step is a larger test, not a verdict.
Common mistakes
- Saying "we accepted H0" or "the test proved there's no effect". A non-significant result means the evidence was not strong enough, often because the sample was too small.
- Writing the hypotheses after seeing the data. Choosing one-sided H1 or a new metric once you know which way the numbers went inflates false positives.
- Treating "reject H0" as "H1 is big and important". With huge samples, trivial differences become significant; check the effect size and confidence interval.
- Stating H0 about the sample instead of the population. The sample means are what they are; hypotheses are about the true conversion rates or averages behind them.
- Testing a vague H1. "The redesign improves things" needs a metric, a direction and, ideally, a minimum effect worth detecting before the test starts.
Learn it in the course
- p-value and significance · What a p-value really says, what it doesn't, and statistical versus practical significance.
- The t-test · Comparing the means of two groups and deciding whether the gap is bigger than chance.
- Power and sample size · How many users an experiment needs to detect the effect you care about.
- ANOVA: comparing many groups · Testing three or more variants at once without inflating false positives.