← All calculatorsStatistics & Probability

Sample Size Calculator

Calculates how many responses you need for a target margin of error and confidence level, including the correction that applies when the population is small.

Next steps

How to use the Sample Size Calculator

  1. Set the margin of error you can live with. ±5% is the common survey standard, ±3% is newspaper-poll grade.
  2. Set the expected proportion; leave it at 50% when you have no prior estimate, since that is the most demanding case.
  3. Enter the population size if the group is small and countable, or leave it at 0 for a large population.
  4. Choose the confidence level.
  5. Use the returned figure as a target for completed responses, then divide by your expected response rate to size the invitation list.

How the calculation works

The formula inverts the margin-of-error expression for a proportion. Because the standard error carries √n in the denominator, sample size enters quadratically: the required n scales with the square of the confidence multiplier and with the inverse square of the margin. Tightening from ±5% to ±2.5% does not cost twice as many responses; it costs four times as many.

Setting the expected proportion to 50% is the conservative default because p(1 − p) is maximised there. If you have credible prior information that the true proportion is near 10% or 90%, using it cuts the required sample by nearly two thirds. Getting that prior wrong in the optimistic direction leaves you with a wider margin than you planned for, so only use it when the evidence is real.

The finite population correction matters when the sample is a meaningful fraction of the whole group. Surveying 400 people from a company of 500 is close to a census and the correction cuts the requirement sharply; surveying 400 from a city of a million changes nothing. This is why national polls in small and large countries need essentially the same number of respondents, a result that reliably surprises people.

Formula
n₀ = z²·p(1 − p) / e²; finite population: n = n₀ / (1 + (n₀ − 1)/N)

Source: Cochran, Sampling Techniques, 3rd edition (1977), chapter 4; Krejcie & Morgan, 'Determining Sample Size for Research Activities', Educational and Psychological Measurement 30 (1970).

Worked example

A ±5% margin at 95% confidence, no prior estimate, population effectively unlimited.

  1. z = 1.96, p = 0.5, e = 0.05.
  2. n₀ = 1.96² × 0.5 × 0.5 ÷ 0.05² = 3.8416 × 0.25 ÷ 0.0025.
  3. n₀ = 0.9604 ÷ 0.0025 = 384.16, rounded up to 385.
  4. For a population of 5,000: 384.16 ÷ (1 + 383.16/5000) = 357.

385 completed responses for a large population, or 357 within a population of 5,000. The origin of the familiar 'about 400 people' rule of thumb.

Frequently asked questions

Why is 385 such a common answer?+

It is the exact result for ±5% at 95% confidence with p = 0.5 and an unlimited population, so it appears in almost every survey methodology note.

Does a bigger population need a bigger sample?+

Barely. Above about 20,000 the required sample is essentially flat, which is why national polls of 1,000 work everywhere.

Is this the number of invitations to send?+

No, it is the number of completed responses. Divide by your expected response rate, at 20%, needing 385 means inviting about 1,925 people.

What if I am measuring a mean rather than a proportion?+

Use n = (z·s/e)² with s as an estimated standard deviation and e as the margin in the same units.

Last reviewed September 1, 2026. We review this page whenever the underlying formula, tax year, published rate or standard changes.

Related

More in Statistics & Probability