About the Margin of Error Calculator
This margin of error calculator tells you how precise a survey or poll result is. Enter the number of people who answered, the confidence level you want (95% is the usual standard) and the observed percentage, and it returns the ± margin of error along with the confidence interval around your result.
It is useful for market researchers sizing up a customer survey, students writing up a statistics project, journalists checking whether a poll lead is meaningful, and anyone reading “±3 points” in a news story and wanting to know where it comes from. If you do not know the proportion yet, leave it at 50% — that gives the largest, most conservative margin.
The calculation assumes a simple random sample. If you sampled a meaningful share of a small, known population, enter the population size and the finite population correction will shrink the margin. It uses the standard normal-approximation (Wald) formula, which is accurate when there are at least about 10 “yes” and 10 “no” answers; for small samples or results near 0% or 100%, NIST recommends an interval such as Wilson’s instead, and the calculator warns you when that applies. Real polls also carry non-sampling error (wording, non-response, weighting) that no formula can capture.
With the default inputs, the margin of error (±) is 3.1%. Change any value above to recalculate instantly.
How to use the margin of error calculator
- 1Enter how many people responded to the survey.
- 2Pick a confidence level — 95% is the convention for most polls.
- 3Enter the percentage who gave the answer of interest, or leave 50% for the worst case.
- 4Optionally enter the population size if you surveyed a small, known group.
- 5Read the ± margin and the confidence interval around your result.
Formula and method
The margin of error is the critical value z for your confidence level multiplied by the standard error of a sample proportion, √(p(1 − p)/n). For 95% confidence z ≈ 1.96, for 90% z ≈ 1.645 and for 99% z ≈ 2.576. Because p(1 − p) peaks at p = 0.5, using 50% gives the widest (most cautious) margin.
The last factor is the finite population correction. It only matters when your sample is a sizeable fraction (roughly 5% or more) of a known population; for large populations it is essentially 1 and is omitted. The interval reported is p ± MOE, clipped to 0–100%. This is the normal-approximation (Wald) interval described in the NIST/SEMATECH e-Handbook; NIST notes that it can misbehave for small samples or proportions near 0 or 1, where the Wilson interval is preferred.
- z
- Critical value of the standard normal distribution for the confidence level
- p
- Sample proportion (as a decimal)
- n
- Sample size
- N
- Population size (optional, for the finite population correction)
Worked examples
National poll of 1,000 people
With n = 1,000, p = 0.5 and z = 1.96, the standard error is √(0.25/1000) = 0.01581, so the margin is 1.96 × 0.01581 ≈ ±3.10 points. That is why national polls of about a thousand people usually quote “±3%”.
Customer survey: 40% of 400 at 90% confidence
At 90% confidence z = 1.645. The standard error is √(0.4 × 0.6 / 400) = 0.02449, so the margin is 1.645 × 0.02449 ≈ ±4.03 points, giving an interval of about 36.0% to 44.0%.
500 of 2,000 employees at 99% confidence
Without correction the margin would be 2.576 × √(0.25/500) = ±5.76 points. Because a quarter of the workforce was surveyed, the correction √(1500/1999) = 0.866 shrinks it to about ±4.99 points.
Frequently asked questions
What is a good margin of error?+
For opinion polls, ±3% to ±5% at 95% confidence is typical. Academic or medical research often aims lower, while quick internal surveys may accept ±5% to ±10%. What matters is whether the margin is small relative to the differences you want to detect.
How does sample size affect the margin of error?+
The margin shrinks with the square root of the sample size. To halve the margin you need four times as many responses, which is why, at 95% confidence and p = 50%, going from ±3% to ±1.5% takes 4,269 responses instead of 1,068.
Why use 50% when I do not know the proportion?+
The product p(1 − p) is largest at p = 0.5, so 50% produces the biggest margin. Using it guarantees your stated margin is never smaller than the real one, whatever the actual result turns out to be.
Does population size matter?+
Barely, for large populations. A sample of 1,000 gives about ±3.1% whether the population is 100,000 or 300 million. The finite population correction only matters when you sample a substantial share (roughly 5% or more) of a small population.
Does the margin of error cover all survey errors?+
No. It only measures random sampling error. Biased samples, leading questions, non-response and weighting choices can add error that is not reflected in the ± figure.
How is the margin of error related to a confidence interval?+
The confidence interval is simply the result plus and minus the margin of error. A 52% result with a ±3% margin gives a 95% confidence interval of 49% to 55%.