An A/B test duration calculator is only as useful as its assumptions. This guide shows how to estimate sample size and runtime from baseline conversion rate, minimum detectable effect, significance level, statistical power, and eligible traffic—then adjust the plan for seasonality, uneven allocation, tracking quality, and responsible stopping rules.
Overview
Experiment duration is the amount of time required to collect enough eligible observations for a planned comparison. It is not simply the time needed to see a few conversions or wait for a result that “looks better.” A reliable estimate starts with the smallest improvement worth acting on and works backward to the required sample.
For a standard two-variant conversion-rate test, the main relationship is:
Required duration = required total sample ÷ eligible experiment traffic per day
The required sample depends on four statistical choices:
- Baseline conversion rate: the current rate for the selected audience and conversion event.
- Minimum detectable effect (MDE): the smallest absolute or relative change that would justify a decision.
- Significance level: the chosen false-positive tolerance, often represented by alpha.
- Statistical power: the probability of detecting the planned effect if it is real.
A duration estimate is a planning tool, not a promise. If traffic, audience mix, conversion behavior, or tracking quality changes, the estimate should be reviewed rather than treated as fixed.
How to estimate
Use this workflow before launching an experiment.
- Define the eligible population. Count visitors, accounts, or sessions that can actually enter the test—not total website traffic. Exclude staff, bots, ineligible geographies, and audiences that cannot see both variants.
- Choose one primary conversion event. Examples include completed checkout, qualified lead submission, or activated account. Secondary metrics can inform the decision, but changing the primary outcome after launch weakens the original plan.
- Establish the baseline. Use a relevant historical period and the same audience definition, device mix, funnel stage, and attribution window where possible. A broad site-wide rate may not represent the landing page being tested.
- Set the MDE. Express it as either a relative change or an absolute percentage-point change. A baseline of 4% increasing to 5% is a 1 percentage-point lift and a 25% relative lift. Calculators need the absolute difference for many standard sample-size formulas.
- Select alpha and power. A two-sided test with alpha of 0.05 and power of 0.80 is a common planning convention, but the appropriate choices depend on decision risk and organizational standards. Record them before launch.
- Calculate sample size for each variant. With equal allocation, a normal-approximation formula for two conversion rates can be represented as:
n per variant ≈ 2 × p̄ × (1 − p̄) × (zalpha/2 + zpower)² ÷ delta²
Here, p̄ is the average planned conversion rate, delta is the absolute MDE, and the z values correspond to the selected significance level and power. A dedicated A/B test sample size calculator may use a more exact method, especially for low conversion rates, unequal allocation, or multiple variants.
- Convert sample to time. Add the sample required for all variants, then divide by eligible daily traffic. Round up and consider a full business or behavioral cycle rather than stopping on the first date the sample threshold is reached.
Before relying on the result, verify that the conversion event is recorded consistently. A useful GA4 tracking plan template can document event names, parameters, conversion definitions, and ownership. If the test relies on multiple tools, review the implementation with a GA4 tracking audit checklist.
Inputs and assumptions
Baseline conversion rate
Use a stable, test-relevant baseline rather than a convenient average. Segment the rate by device or audience when the experiment targets a specific segment. If the baseline is uncertain, calculate a range using plausible low and high values. Low-conversion tests are particularly sensitive to small changes in the starting estimate.
Minimum detectable effect
The MDE should reflect the smallest change that matters commercially or operationally. Setting an unrealistically tiny MDE produces a long test that may not improve decision quality. Setting it too high risks missing a worthwhile but modest improvement. State whether the MDE is relative or absolute in the experiment brief.
Traffic and allocation
Use eligible traffic that reaches the experiment and is assigned correctly. If only 60% of visitors are eligible, do not divide the sample by total site visits. Unequal allocation—such as sending more traffic to a control—changes the sample-size calculation and usually requires a calculator that supports allocation ratios.
Statistical assumptions
Basic formulas often assume independent observations, a stable conversion process, fixed variants, and equal allocation. Those assumptions can be strained when one person generates multiple sessions, purchases have long decision cycles, or users move between devices. Choose a unit of randomization and analysis that matches the experiment design.
Measurement and privacy constraints
Consent choices, browser restrictions, ad blockers, server-side collection, and identity rules can affect observed volume and conversion rates. These systems do not automatically make a test invalid, but they should be applied consistently across variants. Document missing-data rules and check whether one variant has materially different event loss.
Worked examples
Example 1: Landing-page conversion test
Suppose a landing page converts at 5%. The team wants to detect a relative improvement of 20%, which means an alternative rate of 6%. The absolute MDE is therefore 1 percentage point, or 0.01. The test will use two equally sized variants, a two-sided alpha of 0.05, and 80% power.
Using a common normal approximation, the planned average rate is 5.5%. The result is approximately 8,100 eligible visitors per variant, or about 16,200 total visitors. If the experiment receives 200 eligible visitors per day, the statistical estimate is about 81 days:
16,200 ÷ 200 = 81 days
This is a planning estimate, not a recommendation to stop exactly on day 81. The team should also check whether traffic varies by weekday, whether the funnel has delayed conversions, and whether the experiment has run through the relevant behavioral cycle.
Example 2: Why the MDE changes the timeline
Keep the same baseline and traffic, but reduce the target MDE from 1 percentage point to 0.5 percentage points. Because sample size is approximately related to the inverse square of the absolute MDE, detecting a change half as large can require roughly four times as many observations under the same assumptions. A smaller target effect may be worthwhile, but the team should recognize the corresponding cost in time and traffic before approving the test.
Example 3: A test with uneven traffic
If a control receives 70% of traffic and a treatment receives 30%, the smaller group becomes the limiting sample. Do not use a simple total-traffic division without accounting for the allocation ratio. Enter the ratio into an appropriate calculator, or calculate each arm separately and allow for the less-populated variant to reach its requirement.
When to recalculate
Recalculate before launch whenever the baseline, MDE, allocation, primary metric, or eligible traffic estimate changes. Revisit the estimate during the test if a major campaign changes the audience, a product release alters the funnel, tracking is repaired, or traffic becomes materially different from the forecast.
Do not repeatedly recalculate the sample size after looking at the result and stop when significance appears. That practice changes the error properties of the analysis unless the testing method explicitly supports sequential monitoring. Define the stopping rule in advance: for example, reach the planned sample, verify data quality, include a complete behavioral cycle, and then analyze.
At the end of the test, report the planned inputs alongside the result: eligible users per variant, conversions, observed rates, absolute and relative differences, confidence interval, analysis method, and any exclusions. Check guardrail metrics such as revenue quality, cancellation, lead quality, or technical errors before shipping a change. A statistically detectable lift is not automatically a useful product decision.
Keep the calculator inputs with the experiment record so the estimate can be updated when traffic or conversion rates move. Pair the result with a clear tracking log, consistent campaign labeling, and a documented QA process. For experiments affected by consent or collection architecture, review the related Consent Mode v2 implementation guide and server-side measurement considerations before interpreting missing or uneven data.