This sample size calculator tells you how many responses a survey or study needs to hit your target precision: pick a confidence level and margin of error, and get the required sample size for a proportion or a mean.
How Sample Size Works
Before collecting data, researchers decide how precise the answer must be: the margin of error they can tolerate and the confidence level they need. Those two choices, plus how variable the population is, fix the sample size — get it wrong and you either waste money over-sampling or finish a study that cannot answer its own question. Already have a sample? Our Margin of Error Calculator works the equation backwards. This tool is part of our Statistics Calculators collection.
The Formulas
- Proportion: n = Z² × p(1 − p) ÷ E²
- Mean: n = (Z × σ ÷ E)²
- Z comes from the confidence level: 1.645 (90%), 1.96 (95%), 2.576 (99%) — the same z-values as our Z-Score Calculator.
Worked Examples (Verified)
- Survey, 95% confidence, ±5% margin, unknown proportion (use 50%): n = 1.96² × 0.25 ÷ 0.05² = 384.16 → 385 responses — the famous number behind most national polls.
- Estimating a mean with σ = 15 to within ±3 at 95%: n = (1.96 × 15 ÷ 3)² = 96.04 → 97 subjects.
- Tighten the margin to ±3% on the survey: n jumps to 1,068 — precision is bought at inverse-square prices.
Planning Wisdom
- p = 50% is the safe default for proportions — it maximizes p(1−p) and therefore the sample size, so you are covered whatever the true split is.
- Response rate: if you need 385 completions and expect 40% response, invite ~963 people.
- Small populations: enter the population size and the finite-population correction shrinks the requirement — surveying 385 of a 500-person company is overkill; the correction says ~218 suffices.
- Diminishing returns: going from ±5% to ±1% multiplies the sample by 25. Decide what decision the data must support before paying for decimal places.
Related Tools
- Margin of Error Calculator — the reverse problem
- Z-Score Calculator
- Statistics Calculators — the full collection
Frequently Asked Questions
What sample size do I need for a survey?
For a large population at 95% confidence and ±5% margin: 385 responses. At ±3%: 1,068. At ±1%: 9,604. Enter your targets above for exact numbers.
Why use 50% for the expected proportion?
Because p(1−p) peaks at p = 0.5, it gives the largest, safest sample size. If you know the split is lopsided (say 90/10), a smaller sample suffices.
What confidence level should I choose?
95% is the research and polling standard. Use 99% for high-stakes decisions, 90% for exploratory work where cost matters.
Does population size matter?
Only when the sample is a meaningful fraction of the population (rough rule: over 5%). National polls sample 1,000 out of 330 million with no correction needed; a 200-employee company’s survey absolutely needs the correction.
Is 30 a big enough sample?
The “n = 30” rule of thumb concerns when the central limit theorem makes averages roughly normal — it is not a precision guarantee. Sample size should come from your margin-of-error target, not folklore.
Is this sample size calculator free?
Yes — free, instant, no sign-up.