Pollsters choose their sample size before they collect any data. To do that, they turn the confidence interval formula around: they decide how small a margin of error they need and solve for n.
Key idea
$$\text{ME} = z^*\sqrt{\dfrac{p(1 - p)}{n}}.$$ The margin of error shrinks like $1/\sqrt{n}$: to cut it in half you need four times the sample. The sample size for a margin of error $E$ is $$n = \left(\dfrac{z^*}{E}\right)^2 p^*(1 - p^*),$$ rounded up, where $p^*$ is a guess for $p$ (use $0.5$ if you have none).
Why it works
n sits under a square root, so multiplying n by 4 multiplies $\sqrt{n}$ by 2 and divides the margin by 2. Doubling n only divides it by $\sqrt{2} \approx 1.41$. For the sample size, square both sides of $E = z^*\sqrt{p^*(1 - p^*)/n}$ and solve for n. The guess $p^* = 0.5$ is the safe choice: $p(1 - p)$ is largest at $0.5$ (it equals $0.25$ there), so that n is big enough whatever $p$ turns out to be.
Worked example: Scaling the sample
A poll of 600 people has a margin of error of 4 percentage points. What is the margin with 2,400 people? With 1,200?
- 2,400 is 4 times 600, so the margin is divided by $\sqrt{4} = 2$: about 2 points.
- 1,200 is 2 times 600, so the margin is divided by $\sqrt{2} \approx 1.414$: about $4 / 1.414 \approx 2.8$ points.
Answer: About 2 points with 2,400; about 2.8 points with 1,200.
Worked example: Choosing n
How many people must be polled to estimate a proportion within $\pm 0.03$ at 95% confidence?
- No prior guess, so $p^* = 0.5$.
- $$n = \left(\dfrac{1.96}{0.03}\right)^2(0.5)(0.5) \approx 1067.1$$
- Round up to 1,068 (1,067 would give a margin slightly larger than 0.03).
Answer: 1,068 people.
Worked example: Using a prior estimate
An earlier study suggests $p \approx 0.2$. How many are needed for $\pm 0.03$ at 95%?
- $$n = \left(\dfrac{1.96}{0.03}\right)^2(0.2)(0.8) \approx 682.95$$
- Round up: 683. A good guess far from 0.5 saves a lot of sampling.
Answer: 683 people.
Common mistake
Thinking that doubling the sample size halves the margin of error. Because of the square root, doubling n only shrinks it by about 29%; halving it takes 4 times the sample. Check by writing the factor under a square root.
The margin of error covers random sampling variation only. It says nothing about undercoverage, nonresponse or leading questions; a biased poll can be off by far more than its stated margin.