Two Proportion Z Test Calculator

Test two proportions with clear z results. Review pooled estimates, intervals, effect size, and decisions. Export your finished report in seconds for easy records.

Calculator Form

Example Data Table

Scenario First successes First total Second successes Second total Alternative
Landing page test 56 200 43 180 Two sided
Training completion 88 240 69 230 First greater
Defect reduction 12 300 21 310 First less

Formula Used

Sample proportions:

p1 = x1 / n1

p2 = x2 / n2

Pooled proportion:

p = (x1 + x2) / (n1 + n2)

Pooled standard error:

SE = sqrt[p × (1 - p) × (1 / n1 + 1 / n2)]

Z statistic:

z = [(p1 - p2) - d0] / SE

Confidence interval:

(p1 - p2) ± z critical × sqrt[p1(1 - p1) / n1 + p2(1 - p2) / n2]

The calculator also estimates relative lift, risk ratio, odds ratio, Cohen h, and a number needed to treat style value.

How to Use This Calculator

Enter the success count and total sample size for both groups.

Choose the hypothesized difference. Use zero for most equality tests.

Select the alpha level, confidence level, and alternative hypothesis.

Choose pooled testing for a standard zero difference test.

Use continuity correction when you want a more conservative result.

Press calculate. The result appears below the header and above the form.

Use the CSV or PDF button to save the current output.

Understanding the Two Proportion Z Test

A two proportion z test compares two independent rates. It asks whether the observed difference is large enough to reject a chosen null difference. The method is useful for surveys, experiments, quality checks, and A/B tests. Each group supplies a success count and a total count. The calculator turns those counts into sample proportions.

What the Result Means

The z statistic measures distance from the null difference in standard error units. A large positive value supports a greater first proportion. A large negative value supports a smaller first proportion. The p value gives the chance of seeing a result this extreme, assuming the null model is correct. A small p value suggests the observed gap is not random noise.

Confidence Interval Value

The confidence interval estimates the likely range for p1 minus p2. It uses the unpooled standard error. This choice describes the observed samples rather than the strict null model. If the interval excludes zero, the groups differ at the matching two sided significance level. If it includes zero, the evidence is weaker.

When to Use This Tool

Use this calculator when both samples are independent. Use counts, not percentages alone. Each sample should have enough successes and failures for the normal approximation. A common rule checks that expected successes and failures are at least five. For very small samples, consider an exact method instead.

Extra Measures

The calculator also reports risk ratio, odds ratio, absolute difference, relative lift, Cohen h, and number needed to treat when available. These values help explain practical importance. A statistically significant result may still be too small to matter. A large effect may need more data before it becomes significant.

Reporting Tips

Report the sample counts, proportions, z statistic, p value, confidence interval, alpha level, and alternative hypothesis. Mention whether continuity correction was used. Use the CSV export for spreadsheets. Use the PDF export for a quick record. Always add study context before making a decision.

Common Inputs

Choose the alternative before reading the p value. Greater tests ask if the first rate is higher. Less tests ask if it is lower. Two sided tests look for any meaningful difference in either direction. Use consistent definitions.

FAQs

What is a two proportion z test?

It compares two independent sample proportions. It checks whether their observed difference is likely under a selected null hypothesis.

What counts as a success?

A success is the outcome being measured. It may be a click, sale, pass, defect, vote, recovery, or any yes outcome.

Should I enter percentages?

No. Enter success counts and sample totals. The calculator converts those counts into proportions before testing.

When should I use a two sided test?

Use it when any difference matters. It checks for either a higher or lower first proportion.

When is the pooled method suitable?

It is commonly used when testing whether two proportions are equal. That means the null difference is zero.

What does the p value mean?

It is the probability of getting a result this extreme, assuming the null hypothesis is true.

What does the confidence interval show?

It shows a plausible range for the true difference between the two population proportions.

What if my sample is small?

The normal approximation may be weak. Use an exact test when successes or failures are very low.

Related Calculators

Paver Sand Bedding Calculator (depth-based)Paver Edge Restraint Length & Cost CalculatorPaver Sealer Quantity & Cost CalculatorExcavation Hauling Loads Calculator (truck loads)Soil Disposal Fee CalculatorSite Leveling Cost CalculatorCompaction Passes Time & Cost CalculatorPlate Compactor Rental Cost CalculatorGravel Volume Calculator (yards/tons)Gravel Weight Calculator (by material type)

Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.