Sample Size Calculator

Confidence Level
5.0%
Required Sample Size385

Before running a survey you need to know how many responses make the results trustworthy. This calculator applies Cochran’s formula to find the minimum sample size for a chosen confidence level and margin of error, then applies a finite population correction when you supply the total population. It assumes maximum variability (p = 0.5) for a conservative, worst-case estimate.

Formula

n0 = z² × 0.25 / e² ; with population N: n = ceil( n0 / (1 + (n0 − 1) / N) )

z
Z-value for the confidence level (90% = 1.645, 95% = 1.96, 99% = 2.576)
e
Margin of error as a proportion (5% becomes 0.05)
0.25
Maximum variability p(1−p) at p = 0.5, the most conservative assumption
N
Total population size (omit for an effectively infinite population)
n
Required sample size, rounded up to the next whole respondent

How it works

  1. Select a confidence level — 90%, 95%, or 99% — which sets the z-value (1.645, 1.96, or 2.576 respectively).
  2. Enter the margin of error as a percentage (for example 5 for ±5%); the calculator divides it by 100 internally.
  3. Optionally enter the total population size. With no population, the infinite-population formula is used; with one, the result is reduced by the finite population correction. The required sample size is always rounded up to a whole number.

Worked examples

How many people must you survey for 95% confidence and a ±5% margin of error, with no population limit?

  1. z = 1.96 for 95% confidence; e = 0.05.
  2. n0 = 1.96² × 0.25 / 0.05² = 3.8416 × 0.25 / 0.0025 = 384.16.
  3. Round up to the next whole respondent.

Required sample size ≈ 385

Same 95% confidence and ±5% margin, but for a finite population of 1,000 people.

  1. Start from n0 = 384.16 as above.
  2. Apply the correction: 384.16 / (1 + (384.16 − 1) / 1000) = 384.16 / 1.38316 ≈ 277.8.
  3. Round up to the next whole respondent.

Required sample size ≈ 278

Frequently asked questions

Why does the formula assume p = 0.5?
The variability term p(1−p) is largest at p = 0.5, where it equals 0.25. Using that value gives the most conservative (largest) sample size, so your survey stays valid no matter how the responses actually split.
What does the finite population correction do?
When you survey a closed group, you do not need as many responses as for an unlimited population. Supplying the population size shrinks the required sample — for a population of 1,000 the ±5%/95% requirement drops from 385 to 278.
Which confidence levels are supported?
This calculator supports 90%, 95%, and 99% confidence, mapped to z-values of 1.645, 1.96, and 2.576. The 95% level is the most common default in market research and academic surveys.
How is margin of error different from confidence level?
The margin of error is how far your sample result may sit from the true value (the ± band), while the confidence level is how often that band would contain the true value over repeated samples. Tightening either one raises the required sample size.