WordGPT

Sample size for ±5% margin of error at 99% confidence

For a margin of error of ±5% at 99% confidence you need a sample of 664 (using the worst case p = 0.5 and rounding up). If you expect a proportion nearer 0 or 1, fewer are enough.

How to work it out

  1. 1

    The margin of error for a proportion is E = z*·√(p(1−p)/n). Solve it for n.

    n=(z∗)2 p(1−p)E2n = \frac{(z^{*})^{2}\,p(1-p)}{E^{2}}
  2. 2

    The critical value for 99% confidence is z* = 2.576. The margin of error is E = 5% = 0.05.

    z∗=2.576,E=0.05z^{*} = 2.576,\qquad E = 0.05
  3. 3

    Without a prior estimate use p = 0.5, the worst case, which gives the largest n.

    n=2.5762×0.5×0.50.052=663.49n = \frac{2.576^2 \times 0.5 \times 0.5}{0.05^2} = 663.49
  4. 4

    Always round up to the next whole person.

    n=664n = 664
LaTeX source of the formulas on this page
\[ n = \frac{z^{*2}\,p(1-p)}{E^2} = 664 \]
\[ n = \frac{(z^{*})^{2}\,p(1-p)}{E^{2}} \]
\[ z^{*} = 2.576,\qquad E = 0.05 \]
\[ n = \frac{2.576^2 \times 0.5 \times 0.5}{0.05^2} = 663.49 \]
\[ n = 664 \]

Sample size for ±5% at 99% confidence, by expected proportion

Expected proportion pSample size n
0.5664
0.4637
0.3558
0.2425
0.1239
0.05127

Sample size for ±5% at other confidence levels

ConfidenceSample size n (p = 0.5)
80%165
90%271
95%385
98%542
99%664

Questions

How many people do I need for a margin of error of 5% at 99% confidence?

664 (worst case p = 0.5).

Why use p = 0.5?

Because p(1 − p) is largest at 0.5, so the sample size is large enough whatever the true proportion turns out to be.

What if the population is small?

If the sample is more than about 5% of the population, apply the finite population correction n′ = n / (1 + (n − 1)/N), which lowers the number needed.

Other margins of error

Other confidence levels

    Sample size for a margin of error of 5% at 99% confidence: 664 | WordGPT