Margin of Error Calculator

Find the margin of error for your survey or estimate the sample size you need.

± Margin of Error Calculator
Margin of Error
-
Confidence Interval
-
Sample Size (n)
-
Z* Critical Value
-

📖 What is Margin of Error?

The margin of error (MOE) quantifies the uncertainty in a survey or statistical estimate. It tells you how much the sample result might differ from the true population value, at a specified confidence level. A survey result of "52% ± 3%" means the true proportion is estimated to lie between 49% and 55% with the stated confidence.

Margin of error is central to survey research, opinion polling, scientific experiments, and quality control. It depends on three factors: sample size (larger samples = smaller MOE), population variance (more heterogeneous populations = larger MOE), and confidence level (higher confidence = larger MOE because you need a wider interval to be more certain).

Understanding MOE is critical for interpreting surveys correctly. When two candidates are within each other's margin of error (e.g., Candidate A at 51% and Candidate B at 49% with MOE ±3%), the race is statistically too close to call from that poll alone - the difference is within the range of sampling variability.

📐 Formula

MOE = z* × √(p(1−p)/n)

z* = critical value for the confidence level (1.645 for 90%, 1.96 for 95%, 2.576 for 99%)

p = sample proportion (use 0.5 for maximum MOE when unknown)

n = sample size

For a mean (known σ): MOE = z* × σ/√n

Required sample size for target MOE: n = (z*/MOE)² × p(1−p)

Confidence interval: [p̂ − MOE, p̂ + MOE]

📖 How to Use This Calculator

1
Select Calculate MOE to find the margin of error for a given sample size, or Find Sample Size to determine how many respondents you need.
2
Enter the sample size (or target MOE), the expected proportion p (use 0.5 if you don't know - this gives the most conservative/largest MOE), and confidence level.
3
Click Calculate. The MOE, confidence interval around p, and the Z* critical value appear.

📝 Example Calculations

Example 1 - Political Poll

n = 1,000, p = 0.5, confidence = 95%. MOE = 1.96 × √(0.25/1000) = 1.96 × 0.01581 = ±3.10%

If the poll shows 54% support, the 95% CI is [50.9%, 57.1%].

MOE = ±3.10%
Try this example →

Example 2 - Clinical Trial

n = 400, p = 0.72, confidence = 99%. MOE = 2.576 × √(0.72×0.28/400) = 2.576 × 0.02244 = ±5.78%

Observed response rate of 72% has 99% CI: [66.2%, 77.8%].

MOE = ±5.78%
Try this example →

Example 3 - Required Sample Size

Target MOE = ±2%, p = 0.5, confidence = 95%. n = (1.96/0.02)² × 0.25 = 9604 × 0.25 = 2,401

You need at least 2,401 respondents for ±2% MOE at 95% confidence.

Required n = 2,401
Try this example →

Example 4 - Known Proportion

Target MOE = ±3%, p = 0.15 (known from prior research), confidence = 95%. n = (1.96/0.03)² × 0.15×0.85 = 4268 × 0.1275 = 544

With known prior proportion, fewer respondents needed than with p = 0.5.

Required n = 544
Try this example →

Example 5 - 90% Confidence Level

n = 600, p = 0.5, confidence = 90%. MOE = 1.645 × √(0.25/600) = 1.645 × 0.02041 = ±3.36%

Lower confidence = smaller MOE. Same sample gives ±3.10% at 95% and ±3.36% at 90%... wait, lower confidence should give smaller MOE. At 90%: ±3.36% vs 95%: 1.96×0.02041 = ±4.00%. Actually for n=600: 90%: ±3.36%, 95%: ±4.00%, confirming lower confidence = smaller MOE.

MOE = ±3.36% at 90% confidence
Try this example →

❓ Frequently Asked Questions

What is the margin of error?+
The margin of error (MOE) is the maximum expected difference between the sample statistic and the true population parameter, at a given confidence level. For example, a poll showing 54% support with MOE ±3% means the true support is estimated to be between 51% and 57% with the specified confidence (e.g., 95%).
What does 95% confidence level mean?+
A 95% confidence level means that if you repeated the survey many times, about 95% of the resulting confidence intervals would contain the true population parameter. It does NOT mean there is a 95% probability that the true value falls in any one particular interval - the true value either is or isn't in the interval.
How does sample size affect margin of error?+
Margin of error is inversely proportional to √n. Doubling the sample size reduces MOE by a factor of √2 ≈ 1.41. To halve the MOE, you need 4× the sample size. This is why there are diminishing returns to increasing sample size - large samples are expensive but the improvement in precision gets smaller.
What sample size do I need for a ±3% margin of error?+
For a proportion near 0.5 at 95% confidence: n = (1.96/0.03)² × 0.25 ≈ 1068. For ±2%: n ≈ 2401. For ±1%: n ≈ 9604. This is why major national polls use samples of about 1,000 - they give ±3% MOE at 95% confidence.
What is the difference between margin of error and standard error?+
Standard error is the standard deviation of the sampling distribution: SE = √(p(1−p)/n). Margin of error is the critical value times the standard error: MOE = z* × SE. The critical value (z*) depends on the confidence level: 1.645 for 90%, 1.96 for 95%, 2.576 for 99%.
Does margin of error depend on population size?+
For populations much larger than the sample (usually true for polls of thousands), MOE barely depends on population size. For small populations, apply the finite population correction: MOE_corrected = MOE × √((N−n)/(N−1)) where N is population size. This calculator uses the standard formula without correction.