Use this one-proportion z-test calculator to test whether a sample proportion is different from a hypothesized population proportion. You can enter summary data using the number of successes and sample size, or switch to raw data and paste values such as Yes, No, Yes or 1, 0, 1.
After entering your data, choose the test type and significance level to get the sample proportion, z statistic, p-value, decision, conclusion, and step-by-step explanation. This calculator is useful when your outcome has two possible categories, such as yes/no, success/failure, pass/fail, defective/not defective, or support/do not support.
One Sample Proportion Test Calculator
Hypothesis TestingEnter either the number of successes and sample size, or switch to raw data and paste values such as Yes, No, Yes or 1, 0, 1. Then enter the hypothesized proportion, choose the test type, and select the significance level.
Step-by-step explanation
Want to learn the theory behind the test? Read our one-sample proportion z-test guide.
How to Use the One Proportion Z-Test Calculator
This calculator allows you to conduct a one-sample proportion test either using summary data or raw data. If you already know the number of successes (x) and the total sample size (n), you should use the summary data option. However, if you have raw observations listed either as comma-separated text or numbers, use the raw data option.
If you have summary data and want to perform a one-proportion z-test using this calculator, follow these steps:
- Select Summary Data as the input type
- Enter the number of successes (x).
- Enter the sample size (n).
- Enter the hypothesized proportion (p0) as a decimal.
- Choose the test type (right-tailed, left-tailed, or two-tailed).
- Enter the significance level (α) as a decimal.
- Click the Calculate Z Test button.
However, if you’re working with raw data such as: Yes, No, Yes, Yes, No, Yes, No, Yes, where Yes is the success value, you can still perform a one-sample proportion test using this calculator. You only need to follow these simple steps:
- Select raw data as the input type
- Copy-paste the raw data into the input field
- Specify the success value either as text or as a number.
- Enter the hypothesized proportion (p0) as a decimal.
- Choose the test type (right-tailed, left-tailed, or two-tailed).
- Enter the significance level (α) as a decimal.
- Click the Calculate Z Test button.
The calculator will instantly perform the hypothesis test and return the z-test statistic, the p-value, the decision, and the conclusion. You’ll also see a clear, step-by-step explanation, showing you how the hypothesis test was conducted for your data.
Note. If the raw data is numeric, such as 1, 0, 1, 1, 0, 1, and 1 represents success, you should enter 1 as the success value. Otherwise, enter the text representing success, such as Yes, if working with textual data.
One Proportion Z-Test Formula Used by the Calculator
The calculator uses the following z-test statistic formula:
Where:
- p̂ is the sample proportion estimated using the formula, p̂ = x/n
- p0 is the hypothesized population proportion.
- n is the sample size.
Tip. For a one-sample proportion test, the standard error is based on the hypothesized proportion p0, not the sample proportion. This is why we use p0 in the denominator of the z-test statistic formula.
Example 1. One Proportion Z-Test Using Summary Data
Suppose a company claims that 65% of customers prefer its new product design. A researcher surveys 150 customers and finds that 108 prefer the new design. Test whether the true population proportion is different from 0.65 at the 0.05 significance level.
Solution
From the question, we know that:
- The number of successes, x = 108
- The total sample size, n = 150
- The hypothesized proportion, p0 = 0.65
- Significance level, α = 0.05
- Test type is two-tailed since we want to test whether the population proportion is different.
Therefore, to perform the hypothesis using the calculator, enter the above parameters into the calculator, as follows:
| Input | Value |
|---|---|
| Input type | Summary data |
| Number of successes | 108 |
| Sample size | 150 |
| Hypothesized proportion | 0.65 |
| Test type | Two-tailed |
| Significance level | 0.05 |
On clicking the calculate button, the calculator will instantly return the following results:
| Output | Value |
|---|---|
| Sample proportion: p̂ | 0.72 (72%) |
| z statistic | 1.797434 |
| p-value | 0.072267 |
| Decision | Because p = 0.072267 is greater than α = 0.05, we fail to reject the null hypothesis. |
| Conclusion | There is not enough evidence to conclude that the population proportion is different from 0.65. |
Example 2. One Proportion Z-Test Using Raw Data
Suppose a teacher wants to test whether the pass rate in a short quiz is greater than 70%. The results for 25 students are shown below.
Pass, Pass, Fail, Pass, Pass,
Pass, Fail, Pass, Pass, Fail,
Pass, Pass, Pass, Pass, Fail,
Pass, Pass, Pass, Fail, Pass,
Pass, Pass, Fail, Pass, Pass
Perform the hypothesis at the 0.05 significance level.
Solution
From the question, we know that:
- Hypothesized population proportion, p0 = 0.70
- Test type is right-tailed since the teacher wants to test whether the pass rate is “greater.”
Therefore, to perform the hypothesis using the calculator, enter the parameters as shown in the table below.
| Input | Value |
|---|---|
| Input type | Raw data |
| Raw data | Copy-paste the raw data in the input field |
| Success value | Pass |
| Hypothesized proportion | 0.70 |
| Test type | Right-tailed |
| Significance level | 0.05 |
On clicking the calculate button, the calculator will produce the following outputs.
| Output | Value |
|---|---|
| Sample proportion: p̂ | 0.76 (76%) |
| z statistic | 0.654654 |
| p-value | 0.256345 |
| Decision | Because p = 0.256345 is greater than α = 0.05, we fail to reject the null hypothesis. |
| Conclusion | There is not enough evidence to conclude that the population proportion is greater than 0.7. |
Have you already calculated the z-test statistic and only need the p-value? Use our p-value from z calculator to quickly find the p-value for a left-tailed, right-tailed, or two-tailed z test.
When to Use the One-Proportion Z Test Calculator
This calculator is suitable when you want to test whether a sample proportion (p̂) is statistically different from a hypothesized population proportion (p0).
In other words, you can use the calculator when you have one sample and the outcome has only two categories (binary responses), such as:
- Yes / No
- Pass / Fail
- Success / Failure
- Defective / Not defective
- Support / Do not support
- 1 / 0
Examples of hypothesis tests you can perform with this calculator include:
- The proportion of satisfied customers is different from 0.80.
- The pass rate is greater than 0.70.
- The defect rate is less than 0.05.
- The proportion of voters supporting a proposal is different from 0.50.
One-Tailed vs Two-Tailed Test
Choose the test type based on your research question.
| Test Type | Alternative Hypothesis | Use When |
|---|---|---|
| Two-tailed test | H1: p ≠ p0 | You want to test whether the proportion is different from the hypothesized value. |
| Left-tailed test | H1: p < p0 | You want to test whether the proportion is lower than the hypothesized value. |
| Right-tailed test | H1: p > p0 | You want to test whether the proportion is higher than the hypothesized value. |
Note. Always choose the direction before calculating the result because the test direction affects the p-value and the final decision.
Requirements Checked by the Calculator
The calculator checks the normal approximation condition using: np0≥10 and n(1−p0)≥10
If both values are at least 10, the z approximation is usually reasonable. However, if one or both values are below 10, the calculator can still show the z-test result, but an exact binomial test may be a better choice.
You should also make sure that:
- The data come from one sample.
- The observations are independent.
- The outcome has two categories.
- The sample is reasonably representative of the population.
The calculator checks the numeric condition, but it cannot verify your study design.
Frequently Asked Questions
A one-proportion z-test calculator is an online tool used to perform a one-sample proportion test by comparing a sample proportion with a hypothesized population proportion. It gives the z statistic, p-value, decision, and conclusion.
This calculator allows you to enter either summary data or raw data. For summary data, enter the number of successes and sample size. However, for raw data, paste the individual observations and enter the value that should be counted as a success.
The success value is the category the calculator should count as a success. For example, if your raw data are Pass, Fail, Pass, the success value would be Pass.
Enter 50% as 0.50. Proportions should be entered as decimals between 0 and 1.
Yes. Yes/No data are a common use case for a one-proportion z-test. In raw data mode, enter your Yes/No values and set the success value to the category you want to test, such as Yes.
If np0 or n(1−p0) is below 10, the z approximation may not be reliable. In that case, an exact binomial test may be more appropriate.