How to use this calculator
Free Proportion difference confidence interval calculator. Build a normal-approximation interval for the difference between two independent proportions.
- Enter Group 1 events / Group 2 events, Group 1 sample size / Group 2 sample size, Confidence level (%). Match the units shown beside each field and review the result together with the assumptions below.
- Read the worked example below to check the expected input format and result.
- Compare another scenario by changing one input at a time. Use Reset to return to the starting values.
Estimate a range for the difference between two rates
This page builds a Wald confidence interval for p₁ − p₂ using two independent samples. The sign is tied to the group order: a negative difference means the first sample proportion is lower.
Inputs for this calculation
- Group 1 events / Group 2 events: Counts of the same binary outcome in the two groups.
- Group 1 sample size / Group 2 sample size: Total observations in each independent sample.
- Confidence level (%): Select a level between 0 and 100; the calculator uses a two-sided normal critical value.
Formula and method
For each group, divide events by its sample size to get p̂₁ and p̂₂. Their estimated contrast is p̂₁ − p̂₂; its unpooled standard error is √[p̂₁(1 − p̂₁)/n₁ + p̂₂(1 − p̂₂)/n₂]. The interval extends z* standard errors on either side of that contrast.
Worked example
For 12/40 and 18/60, both estimates are 30%, so p̂₁ − p̂₂ = 0. The unpooled SE is √[0.3×0.7/40 + 0.3×0.7/60] = 0.09354. At 95%, the interval is 0 ± 1.96×0.09354, or about −18.33 to +18.33 percentage points.
Reading the result
The interval shows the values for the population difference that are compatible with this estimate and method at the selected confidence level. Here it includes zero and differences in either direction; it does not establish equality.
Assumptions and limits
The Wald interval is a large-sample normal approximation and can perform poorly for small samples or proportions near 0 or 1. For sparse data, consider a score-based or exact method suited to the study design.
Method references
Frequently asked questions
Does an interval containing zero prove there is no difference?
No. It says zero is among the values not ruled out by this interval. The data may still be compatible with meaningful positive or negative differences.
How do I use the Proportion difference confidence interval calculator?
Enter Group 1 events / Group 2 events, Group 1 sample size / Group 2 sample size, Confidence level (%). Match the units shown beside each field and review the result together with the assumptions below.
What is a worked example of Proportion difference confidence interval?
For 12/40 and 18/60, both estimates are 30%, so p̂₁ − p̂₂ = 0. The unpooled SE is √[0.3×0.7/40 + 0.3×0.7/60] = 0.09354. At 95%, the interval is 0 ± 1.96×0.09354, or about −18.33 to +18.33 percentage points.
What does the Proportion difference confidence interval calculator calculate?
Free Proportion difference confidence interval calculator. Build a normal-approximation interval for the difference between two independent proportions.
What assumptions apply to Proportion difference confidence interval?
The Wald interval is a large-sample normal approximation and can perform poorly for small samples or proportions near 0 or 1. For sparse data, consider a score-based or exact method suited to the study design. Worked example: equal observed proportions, with uncertainty from two finite samples.