What it does
When a poll asks 400 people instead of everyone, its answer is only an estimate. The margin of error says how far the estimate is likely to be from the truth, and “95%” means that if you ran the poll again and again, about 95 out of 100 of the bars would reach the true share. This page lets you do exactly that, 100 polls at a time, and count how many bars miss.
Each row on the graph is one poll: a dot for what it found and a bar for its margin of error. Bars that miss the true share (the orange line) turn red. The size of the margin depends on how many people you ask and on the share itself. See normal curve lab for the bell curve behind the rule and hypothesis tests for the next step.
How to use it
- Set the true share saying yes (say 50%) and the number of people asked.
- Look at the margin of error in the sentence under the graph.
- Press “Run 100 new polls” and read how many bars caught the true share.
- Change n and run again. Watch the bars get narrower or wider.
- Answer the quiz questions at the bottom.
What each setting does
- True share saying yes: the real percentage in the whole town.
- People asked (n): the sample size. More people means narrower bars.
- Run 100 new polls: redraws with a new random sample for every poll.
Worked example
A poll of 1,000 people finds 50% yes. The margin is 1.96 × √(0.5 × 0.5 ÷ 1000) = 0.031, so about ±3.1 points. To get ±3% in the worst case you need n = (1.96 ÷ 0.06)² ≈ 1,068 people. To halve the margin you need four times as many people.
FAQs
Does the margin cover bad questions or people who do not answer? No. It only covers the chance variation from sampling.
Why do about 5 bars miss? A 95% rule is wrong 5 times in 100 by design.
Why use 1.96? It is the number of standard deviations that holds the middle 95% of a normal curve.
Where the numbers come from
- The margin of error for a sample proportion, 1.96 × √(p̂(1 − p̂) ÷ n), and the worst-case sample size are standard statistics (Common Core HS-S-IC.4 to 6). Checked against hand-worked values in tests/sci.mjs. Polls are simulated with a normal approximation, so nothing real is shown.
Standard scientific values, such as constants, atomic weights and melting points, are facts found in every textbook; we name where ours were checked. If you are an author or publisher and want a value, a credit or a table changed or removed, tell us and we will act quickly.
Last updated 2026-11-16.