👥 Sample Size Calculator

How many people a survey needs for a given margin of error and confidence level. It also applies the finite population correction, which matters a great deal when the group you are sampling is small.

Use 50 if unknown. It is the worst case and needs the largest sample.
Leave at 0 for an effectively infinite population. Matters below about 100,000.

How many people a survey needs, and why a thousand is usually enough

The most counterintuitive fact in survey research is that the size of the population barely matters. A sample of 1,068 gives a margin of error of about three points whether you are polling a town of 50,000 or a country of 300 million. What determines accuracy is the absolute size of the sample, not the fraction of the population it represents.

n = z² × p(1−p) / e²

z is the score for your confidence level, p the expected proportion and e the margin of error as a decimal. With 95% confidence (z = 1.96), p set to 0.5 and e at 0.03, this gives 1,067.1, rounded up to 1,068 — which is why national polls cluster in that range.

The square-root penalty

Sample needed at 95% confidence, large population
Margin of errorSample size
±1 point9,604
±2 points2,401
±3 points1,068
±5 points385
±10 points97

Halving the margin of error requires four times the sample, because the error falls with the square root of n. Going from ±3 to ±1.5 points means 4,269 respondents instead of 1,068 — four times the cost for a gain most readers would not notice. This is the whole economics of survey research in one line, and it is why almost nobody pays for ±1.

Why p = 0.5 is the safe assumption

The term p(1−p) is largest when p is 0.5, where it equals 0.25. At p = 0.9 it falls to 0.09, needing only 36% as many respondents. Since you rarely know the proportion before asking, using 0.5 gives the largest sample the question could require and therefore guarantees the margin of error you promised.

If you have a solid prior estimate — a previous wave of the same survey, or a rare condition with known prevalence — using it legitimately reduces the sample. Using an optimistic guess to justify a smaller sample is the most common way a survey quietly fails to deliver the precision stated in its methodology.

The finite population correction only bites when your sample is a large fraction of the population. For a population of 1,000 it cuts the required sample from 1,068 to 517; for a population of 100,000 it cuts 1,068 to 1,056. Below about a 5% sampling fraction the correction is not worth applying.

Margin of error applies to the whole sample, not the subgroups

A poll of 1,000 with a ±3 point margin reports on 400 women with a margin of about ±4.9 points, and on 120 young voters with a margin of about ±8.9. Every crosstab in a survey is a smaller survey with a correspondingly wider margin, and the headline figure quoted at the top does not apply to any of them.

Margin of error by subgroup size, 95% confidence
Subgroup sizeMargin of error
1,000±3.1 points
500±4.4 points
250±6.2 points
100±9.8 points
50±13.9 points

This is where most over-interpretation of polling happens. A ten-point gap between two subgroups of 100 respondents each is well inside the combined noise, and reporting it as a finding is a statistical error rather than a judgement call. The confidence interval calculator gives the interval for any single estimate.

What the formula cannot protect you from

Margin of error describes sampling error only — the luck of who happened to be selected. It says nothing about the far larger errors that come from a sample that is not random: a survey of your own mailing list, a poll where only the motivated respond, a question worded to suggest its answer, or respondents who misreport what they do.

A biased sample of a million is worse than a random sample of a thousand, because the bias does not shrink with size while the stated margin of error does, giving false precision. The 1936 Literary Digest poll had 2.3 million responses and called the US presidential election wrongly by nineteen points, because its sample was drawn from telephone and car owners. Sample quality is a separate problem from sample size and no formula addresses it.

A worked example

A company with 4,200 employees wants satisfaction measured to ±4 points at 95% confidence. The infinite-population formula gives 601; the finite population correction brings it to 526. Expecting a 35% response rate, they need to invite about 1,503 people. They also want to report by department, and the smallest has 90 staff — so to say anything about that department they must survey nearly all of it, which is a design decision the headline sample size would have hidden.

Most people arrive here on the way to something else, so it is worth knowing the confidence interval calculator, which handles the next part, and the z-score calculator, which covers the case just beyond.

Frequently Asked Questions (FAQs)

How many people do I need to survey?

For a margin of error of three points at 95% confidence, about 1,068 regardless of how large the population is. Five points needs 385 and ten points needs 97. The population size only matters when your sample would be more than about 5% of it.

Why does population size barely matter?

Because accuracy comes from the absolute number of independent observations, not from the fraction of the population sampled. Once a sample is large enough to represent the variety in the population, adding population does not add uncertainty — which is why national and city polls use similar sample sizes.

What is margin of error?

The range around your result within which the true value probably lies, at your stated confidence level. A result of 52% with a margin of three points at 95% confidence means that if you repeated the survey many times, 95% of the intervals built this way would contain the true figure.

What should I use for the expected proportion?

Use 0.5 unless you have a solid prior estimate. It maximises the required sample and therefore guarantees your stated margin of error whatever the answer turns out to be. A lower assumption shrinks the sample but risks missing the precision you promised.

Why do I need four times the sample to halve the error?

Because error falls with the square root of the sample size, so cutting it in half means multiplying n by four. Moving from three points to one and a half points takes 4,269 respondents instead of 1,068, which is why very tight margins are rarely bought.

Does the margin of error apply to subgroups?

No. Each subgroup is effectively a smaller survey with a wider margin: 100 respondents carry about ten points of error, not three. Most over-reading of survey results comes from applying the headline margin to a crosstab.

Is a bigger sample always better?

Only if it is drawn the same way. A biased sample gets more precisely wrong as it grows, because the bias does not shrink while the stated margin of error does. The Literary Digest poll of 1936 had 2.3 million responses and missed the result by nineteen points.