A worked example: 95% confidence, 5% margin, unknown population
Targeting 95% confidence with a 5% margin of error, assuming the most conservative 50% expected proportion, requires a sample of 385 — a figure widely cited as a standard survey size for exactly this reason.
The formula: n = Z² × p(1−p) ÷ E²
Z comes from the chosen confidence level, p is the expected proportion (the fraction expected to answer a certain way), and E is the target margin of error as a decimal. The result is always rounded up, since a sample size is a whole count of people.
Tightening the margin: 3% instead of 5%
The same 95% confidence and 50% proportion assumption, but tightened to a 3% margin of error, requires 1,068 respondents — nearly three times the 385 needed for a 5% margin, since margin of error sits in the denominator squared: cutting it to three-fifths raises the required sample by roughly (5÷3)², close to the actual 2.8× increase.
Why 0.5 is the safe default proportion
p(1−p) is largest when p = 0.5 (0.5 × 0.5 = 0.25, the maximum possible value of that product) — so assuming a 50/50 split before any data exists guarantees a sample size large enough for whatever the true proportion turns out to be, at the cost of surveying more people than a lucky guess at the real proportion might have required.
Why a bigger population doesn't need a proportionally bigger sample
Once the population is much larger than the sample already needed, growing the population further barely changes the required sample size — the finite-population correction only meaningfully shrinks the sample when the population is small relative to it, which is why national surveys with millions of people still only need a few hundred to a few thousand responses.