Ab Test Guide Sample Size Calculator

AB Test Guide Sample Size Calculator

Estimate the right traffic before you launch your experiment

Use this premium calculator to estimate sample size per variant for a two-group A/B test on conversion rate. Enter your baseline rate, minimum detectable lift, confidence level, power, and daily traffic to forecast how large your experiment should be and how long it may run.

Example: 5 means your current page converts at 5%.

Example: 10 means you want to detect a 10% relative lift.

Used to estimate test duration for equal traffic split.

This calculator assumes a balanced design, which is standard for planning conversion-focused A/B tests.

Your result

Required sample sizes update after calculation and include an estimated runtime based on the traffic you entered.

Per group sample sizeReady to calculate
Total sample sizeEnter values
Expected variant ratePending
Estimated durationPending

Tip: Smaller effects require much larger samples. If your minimum detectable lift is too aggressive, your test may need weeks of traffic.

How to use an AB test guide sample size calculator the right way

An A/B test only works when it has enough data to separate real performance differences from random noise. That is why an AB test guide sample size calculator is one of the most important planning tools in experimentation. Teams often focus on creative ideas, landing page variants, or button color changes, but the real foundation of a trustworthy test is statistical design. If your sample is too small, you are at high risk of false winners, unstable conversion lifts, and decisions that look impressive in a dashboard but disappear in production. If your sample is too large, you delay learning and waste traffic that could be used on the next experiment.

This calculator is designed for conversion rate experiments where you compare two proportions, such as checkout completion, sign-up conversion, lead form submission, email click rate, or free trial activation. It estimates the visitors you need per variant using a standard two-sided hypothesis test for proportions. In plain language, it tells you how many users should see version A and version B before you can reasonably expect to detect a meaningful difference with the confidence and power you choose.

Core planning principle: sample size depends on four inputs more than anything else: your baseline conversion rate, your minimum detectable effect, your confidence level, and your statistical power. When any one of these becomes more demanding, required sample size rises, sometimes dramatically.

What each calculator input means

  • Baseline conversion rate: This is the current conversion rate of your control experience. If your page converts at 5%, then 5 out of every 100 visitors complete the target action.
  • Minimum detectable lift: This is the smallest relative improvement you care enough to detect. A 10% relative lift on a 5% baseline means your target variant conversion rate is 5.5%.
  • Confidence level: This reflects your tolerance for Type I error, often called false positives. At 95% confidence, your alpha is 5% for a two-sided test.
  • Power: This reflects your tolerance for Type II error, often called false negatives. At 80% power, your design has an 80% chance of detecting the target effect if it truly exists.
  • Traffic per day: This does not change the required sample size itself, but it tells you how long the experiment may need to run.

Why sample size matters so much in experimentation

Underpowered tests are one of the biggest reasons A/B programs fail to scale. A team launches a test with enthusiasm, sees a double-digit lift after a few days, and declares victory. Then the result fades after rollout, or the next test contradicts the earlier one. This happens because early results are volatile, especially when event counts are low. Sample size planning protects your organization from that volatility.

When your experiment has enough users, three good things happen. First, the estimate of conversion difference becomes more stable. Second, the confidence interval narrows, making your decision more reliable. Third, your odds of wasting engineering or media budget on a false winner drop substantially. That is why strong experimentation teams use a pre-test sample size calculator before design approval, not after a campaign is already running.

The statistics behind the calculator

For a simple two-group A/B test on conversion rate, a common planning formula for equal group sizes is based on a z-test for proportions. The calculator estimates the sample per group needed to detect the difference between a control rate and a target treatment rate.

n = ((z(alpha/2) * sqrt(2 * pbar * (1 – pbar)) + z(beta) * sqrt(p1 * (1 – p1) + p2 * (1 – p2)))^2) / (p2 – p1)^2

In that expression, p1 is the baseline conversion rate, p2 is the expected variant conversion rate, pbar is the average of the two rates, z(alpha/2) is tied to your confidence level, and z(beta) is tied to your desired power. Although the formula looks technical, its practical meaning is straightforward. Small expected improvements are hard to detect, so they require more traffic. Large expected improvements are easier to detect, so they need less traffic.

Confidence, alpha, power, and beta

These terms are often confused, so it helps to separate them clearly:

  1. Confidence level is usually 90%, 95%, or 99%.
  2. Alpha is the false-positive rate. At 95% confidence, alpha is 0.05.
  3. Power is usually 80% or 90%.
  4. Beta is the false-negative rate. At 80% power, beta is 0.20.

Lower alpha and higher power both increase sample size. That tradeoff is not bad; it is simply the cost of wanting stronger evidence.

Setting Statistic Value Why it matters for A/B testing
90% confidence Two-sided z critical value 1.645 Requires less evidence than 95%, so sample size is lower but false-positive risk is higher.
95% confidence Two-sided z critical value 1.960 The most common default for product and marketing experiments.
99% confidence Two-sided z critical value 2.576 Stricter evidence threshold, useful when rollout risk is very high.
80% power z value for power 0.842 A common default that balances speed and reliability.
90% power z value for power 1.282 Detects true effects more reliably but needs more users.
95% power z value for power 1.645 Often reserved for very high-stakes decisions or large traffic environments.

How baseline rate and minimum detectable effect change your required traffic

Two experiments can target the same relative lift and still require very different sample sizes. A baseline conversion rate near 50% has more variance than a rate near 1% or 99%, which changes the denominator in the planning formula. At the same time, the smaller the lift you want to detect, the smaller the difference between A and B. Small differences are statistically expensive, which is why many mature programs tier their tests by business importance.

If you are testing a major checkout redesign, it may be worth waiting for enough traffic to detect a 5% relative lift. If you are testing hero copy on a low-traffic page, you may choose a larger minimum detectable lift, such as 15% or 20%, because only larger gains would justify implementation anyway.

Baseline conversion rate Relative lift target Expected variant rate Approximate sample per group at 95% confidence and 80% power
2.0% 10% 2.2% About 38,000 visitors per group
5.0% 10% 5.5% About 31,000 visitors per group
10.0% 10% 11.0% About 14,700 visitors per group
5.0% 5% 5.25% About 123,000 visitors per group
5.0% 20% 6.0% About 8,100 visitors per group

These figures illustrate one of the most useful truths in experimentation: detecting tiny gains is expensive. If you cut the lift target in half, sample size usually does far more than double. That is why business context matters. The right minimum detectable effect is not just a statistical choice. It is an operational and economic choice.

How to choose realistic settings for your experiment

1. Start with your business threshold

Ask what minimum improvement would actually change a decision. If a 1% relative lift is too small to matter financially, do not design your test around it. Use a threshold that reflects revenue, lead quality, or customer value.

2. Use a stable baseline rate

Do not use a baseline from a single day unless your volume is enormous. Use a representative historical window that accounts for weekday mix, campaign traffic, and seasonality. For many teams, the last two to six weeks is a better planning reference than yesterday alone.

3. Match confidence and power to risk

For routine website tests, 95% confidence and 80% power are common. For experiments tied to pricing, compliance, or major user experience changes, stricter settings may be appropriate. Just remember that stronger guarantees cost more traffic and time.

4. Respect full business cycles

Even if your sample size is reached quickly, avoid ending a test before it experiences a full cycle of user behavior. Weekly patterns matter in ecommerce, B2B lead generation, and subscription products. A test that spans only a narrow slice of traffic can be directionally wrong.

Common mistakes when using a sample size calculator

  • Stopping early because results look good: Early lifts are often inflated.
  • Ignoring multiple variants: More groups split your traffic and increase total runtime.
  • Using unrealistic MDE values: If your site does not have the traffic, chasing tiny effects can block your roadmap.
  • Forgetting data quality: Bot traffic, duplicate events, and attribution bugs can make even a perfectly sized test unreliable.
  • Changing the primary metric mid-test: This weakens the logic of your sample size plan and can invalidate decisions.

Interpreting calculator output like an expert

When you click calculate, focus on four outputs. First, the sample per group tells you the minimum number of visitors each variant should receive. Second, the total sample tells you how much traffic the whole experiment needs across all groups. Third, the expected variant rate translates your MDE into an intuitive performance target. Fourth, the estimated duration shows whether the test is practical under current traffic conditions.

If the duration is too long, do not immediately lower confidence or power. First ask whether you can test a bigger change, combine traffic sources safely, reduce the number of variants, or move the experiment to a higher-volume page. Those adjustments usually produce healthier experimentation programs than simply weakening your statistical standards.

Recommended standards and learning resources

If you want to go deeper into hypothesis testing, statistical power, and two-proportion comparisons, these sources are worth reviewing:

Final takeaway

An AB test guide sample size calculator is not just a utility. It is a decision-quality tool. It helps you translate business goals into defensible test design, decide whether an experiment is feasible before launch, and avoid the costly trap of reading too much into too little data. The best experimentation teams do not guess how much traffic they need. They calculate it, document it, and hold the line until the test has enough evidence to support action.

Use this calculator at the planning stage of every test. Pair it with a clear primary metric, a realistic minimum detectable effect, and a commitment to complete the run across a representative business cycle. When you do that consistently, your A/B program becomes faster, more trustworthy, and far more valuable.

Leave a Reply

Your email address will not be published. Required fields are marked *