Home / Sample Size Calculator

Sample Size Calculator

Find the sample size you need for surveys and A/B tests.

Details

Results

Required sample size
Unadjusted (infinite pop.)
Z-score

Computed with standard statistical methods in your browser.

How it works

Sample size n₀ = z²·p(1−p) ÷ e², where z comes from your confidence level, p is the expected proportion and e is the margin of error. For a known population we apply the finite population correction.

Tip: use p = 50% when unsure — it gives the largest, safest sample size.

StatsCalc has more free tools

Run the rest of your analysis with our other free stats tools.

Good to know

FAQs

How is sample size calculated?

Using n = z²·p(1−p)/e², adjusted for population size when known.

What confidence level should I use?

95% is standard; 99% needs a larger sample, 90% a smaller one.

What is margin of error?

The ± range around your result; 5% is common for surveys.

Why use 50% proportion?

It maximizes variance, giving the most conservative (largest) sample size.

Do I need the population size?

Only for small populations; for large ones the correction barely matters.