Quick Answer
A p-value is the chance of getting a test result at least as extreme as yours if the null hypothesis is true. A two-tailed z-score of 1.96 gives p = 0.0500. A t-score of 2.5 with 10 degrees of freedom gives a two-tailed p = 0.0314. If p is below your significance level, usually 0.05, the result is called statistically significant.
Embed this calculator
Adjust the size if needed, then copy the code below into your page or blog. The calculator will load in an iframe and stay updated automatically.
Table of Contents
- P-Value Calculator
- Quick Answer
- Related Calculators
- How This P-Value Calculator Works
- How to Use the P-Value Calculator
- Core Formulas
- Key Terms
- Worked Example
- Real-Life Examples
- P-Value vs Significance Level
- Common Critical Values
- Choosing the Tail
- Common Mistakes to Avoid
- Frequently Asked Questions
- References & Sources
How This P-Value Calculator Works
Choose the kind of test statistic you have, enter its value and the degrees of freedom, and pick the tail. The calculator finds the area under the matching distribution curve, which is the p-value, and compares it with your significance level.
Quick explanation: a small p-value means your result would be rare if there were no real effect.
- Z: large samples or a known standard deviation.
- T: small samples with an estimated standard deviation.
- Chi-square: counts, such as goodness of fit or independence tests.
- F: comparing variances, ANOVA and regression.
How to Use the P-Value Calculator
- Choose the test statistic: z, t, chi-square or F.
- Enter the value of the statistic from your test.
- Enter the degrees of freedom, if asked.
- Choose two-tailed, left-tailed or right-tailed, and enter your significance level.
- Press Calculate and read the p-value and whether the result is significant.
Core Formulas
- Right-tailed: p = P(T ≥ t)
- Left-tailed: p = P(T ≤ t)
- Two-tailed: p = 2 × the smaller of the two tail areas
- Decision: reject the null hypothesis if p < α
T is the test statistic and its distribution, and t is the value you got. For a z or t test, the two-tailed p-value is 2 × P(T ≥ |t|).
Key Terms
- Null hypothesis (H₀): the starting claim that there is no effect or no difference.
- Alternative hypothesis (H₁): the claim that there is an effect or difference.
- Test statistic: a number from your data, such as z or t, that measures how far it is from the null hypothesis.
- Degrees of freedom: a number tied to sample size that sets the shape of the t, chi-square or F curve.
- Significance level (α): the cut-off for rejecting the null hypothesis, often 0.05.
Worked Example
A two-sample t-test gives t = 2.3 with 24 degrees of freedom. You use a two-tailed test at α = 0.05.
- Area to the right of 2.3 = 0.0152
- Two-tailed p-value = 2 × 0.0152 = 0.0304
- 0.0304 < 0.05, so the difference is statistically significant
Real-Life Examples
- A/B test: a website test gives z = 2.1. The two-tailed p-value is 0.0357, so the change is significant at the 5% level.
- Class experiment: a paired t-test with 9 students gives t = 1.8 and df = 8. The two-tailed p-value is 0.1096, so it is not significant at 0.05.
- Survey counts: a chi-square test of independence gives χ² = 9.5 with 4 degrees of freedom. The p-value is 0.0497.
- ANOVA: comparing three groups of 10 gives F = 4.2 with df = (2, 27). The p-value is 0.0258.
P-Value vs Significance Level
- P-value: calculated from your data. It changes from study to study.
- Significance level (α): a cut-off you choose before the test, often 0.05 or 0.01.
- Decision: if p < α, reject the null hypothesis. If not, you do not have enough evidence to reject it.
- Effect size: neither one tells you how big or important the effect is.
Common Critical Values
A statistic beyond these values gives a p-value below the column heading.
| Test | p = 0.10 | p = 0.05 | p = 0.01 |
|---|---|---|---|
| Z (normal) | 1.645 | 1.960 | 2.576 |
| t, df = 5 | 2.015 | 2.571 | 4.032 |
| t, df = 10 | 1.812 | 2.228 | 3.169 |
| t, df = 20 | 1.725 | 2.086 | 2.845 |
| t, df = 30 | 1.697 | 2.042 | 2.750 |
| Chi-square, df = 1 (right tail) | 2.706 | 3.841 | 6.635 |
| Chi-square, df = 2 (right tail) | 4.605 | 5.991 | 9.210 |
Choosing the Tail
- Two-tailed: you test for any difference, higher or lower. This is the safe default.
- Right-tailed: you only test whether the value is greater. Chi-square and F tests use this.
- Left-tailed: you only test whether the value is smaller.
- Decide first: choose the tail before you look at the data, not after.
Common Mistakes to Avoid
- Reading p as the chance the null is true. It is the chance of data this extreme if the null is true.
- Choosing the tail after seeing the data. This makes results look stronger than they are.
- Treating 0.05 as a magic line. p = 0.049 and p = 0.051 give almost the same evidence.
- Using a z-test for small samples. Use a t-test when the standard deviation is estimated from a small sample.
- Ignoring effect size. With a huge sample, even a tiny effect can be significant.
Frequently Asked Questions
It is how likely you would be to see results this extreme if there were really no effect. Smaller means stronger evidence against the null hypothesis.
Most fields use p < 0.05. Some use 0.01 or stricter, such as particle physics.
Find the area beyond the z-score under the normal curve. For a two-tailed test, double the smaller tail. This calculator does it for you.
Use the t distribution with the right degrees of freedom. For a one-sample t-test, df = n − 1.
Use two-tailed unless you decided before the study that only one direction matters.
No, but it can be very small. Very small values are shown in scientific notation, such as 2.1e-8.
No. A p-value is a probability, so it is between 0 and 1.
If the null hypothesis were true, you would see a result this extreme about 5% of the time.
For a goodness-of-fit test, use categories − 1. For a table, use (rows − 1) × (columns − 1).
In one-way ANOVA, the numerator df is groups − 1 and the denominator df is total sample size − groups.
No. It only shows the effect is unlikely to be zero. Check the effect size and confidence interval too.
A two-tailed test counts extreme results in both directions, so it adds both tail areas.
References & Sources
| Source | Used For | Link |
|---|---|---|
| NIST/SEMATECH e-Handbook of Statistical Methods | Hypothesis tests and distributions. | https://www.itl.nist.gov/div898/handbook/ |
| NIST, Critical values of the Student’s t distribution | The t table used to check the values here. | https://www.itl.nist.gov/div898/handbook/eda/section3/eda3672.htm |
| Wikipedia, P-value | Definition and examples. | https://en.wikipedia.org/wiki/P-value |