A/B Sample Size Calculator

Plan test size for two proportions.

Inputs: baseline rate, min detectable effect, power, alpha.

Sample per variant
—
Total sample
—

How it works

This calculator helps you determine how many visitors you need to test if a change (like a new button color or headline) actually improves your conversion rate.

You provide your current conversion rate (baseline), the minimum improvement you want to detect, and how confident you want to be. The calculator tells you how many people need to see each version.

  • Baseline rate: Your current conversion rate (e.g., 10% of visitors buy)
  • Min detectable effect: The smallest improvement you want to detect (e.g., 2% absolute or 20% relative)
  • Power: How likely you are to detect the effect if it exists (80% is standard)
  • Alpha: How likely you are to falsely claim an effect (5% is standard)

The calculator uses statistical formulas to ensure your test has enough statistical power to reliably detect meaningful differences between your control and treatment groups.

FAQs

What's the difference between absolute and relative effects?

Absolute: If your baseline is 10% and you want to detect a 2% improvement, you're looking for 12%. Relative: A 20% improvement means you're looking for 12% (10% × 1.2).

Why do I need so many visitors?

Smaller effects require larger samples to detect reliably. A 1% improvement needs more visitors than a 5% improvement to be statistically significant.

What if I can't get enough traffic?

Consider testing larger effects, running longer tests, or focusing on higher-traffic pages. You can also reduce power (e.g., to 70%) for smaller sample sizes.

How accurate are these estimates?

These are theoretical minimums. Real-world factors like seasonality, traffic quality changes, and implementation issues may require larger samples.