How it works
Cochran's formula gives the sample for an unlimited population from the confidence level's z value and the margin of error, using the worst case share of 50%. When the total population is known, a finite correction shrinks the sample. The answer is rounded up, because you can always survey one more person.
Formula
With a population P: n adjusted = n ÷ (1 + (n − 1) ÷ P).
z = 1.645 (90%), 1.96 (95%), 2.576 (99%).
Round up.
Example
Example in plain words. 95% confidence and a 5% margin, unlimited population.
n: 1.96² × 0.25 ÷ 0.05² = 384.16, so survey 385 people.
If the population is 10,000: 384.16 ÷ (1 + 383.16 ÷ 10,000) = 369.98, so 370 people.
Frequently asked questions
Why 50% as the share?
The product p × (1 − p) peaks at p = 0.5, so assuming it gives the largest, safest sample for any question.
What does 95% confidence mean?
That the method captures the true population value in 95 out of 100 repeats of the survey.