P Value Calculator

By Easy Stat CalcLast updated December 1, 2026

This free online p value calculator turns a test statistic into a p-value. Choose z, t, chi-square, F or Pearson r, enter the statistic (and the degrees of freedom when needed), pick a two-tailed, right-tailed or left-tailed test and set alpha. The p-value calculator shows the exact p-value, whether to reject or fail to reject the null hypothesis, each formula step written out with your numbers, and a shaded curve of the tail area. Everything runs in your browser, and extremely small p-values are shown in full instead of as zero.

Loading calculator…

What is a p-value?

A p-value is the probability of getting a test statistic at least as extreme as the one you observed, assuming the null hypothesis is true. In other words, it measures how surprising your result would be if nothing were going on. The smaller the p-value, the harder it is to explain your data by chance alone, which is the p value meaning in statistics. The standard p-value definition adds one condition: the null hypothesis must be true when you compute it. The letter p is the symbol for this probability, and a p-value explained in plain words is a measure of how surprising your result is. The p value in research is the number you report next to every test.

Two details matter. First, “extreme” depends on the alternative hypothesis: a left-tailed test counts only very low values, a right-tailed test only very high values, and a two-tailed test counts both ends. Second, a p-value is a statement about the data given the null hypothesis. It is not the probability that the null hypothesis is true, and it does not tell you how large or important an effect is. A small p-value also does not prove an effect: if you reject a true null hypothesis you make a type I error, and the significance level alpha is the risk of that error you accept in advance.

P-value formulas for each tail

The p-value equation depends on the tail. Every p-value is read from the cumulative distribution function (cdf) of the test statistic when the null hypothesis holds, written F(x) below. The tail you choose decides which area you measure.

P-value formula for each tail of a test
Tailp-valueUse it when
Left-tailedp = F(x)the alternative says the value is lower than the null
Right-tailedp = 1 − F(x)the alternative says the value is higher than the null
Two-tailed, symmetric (z, t, r)p = 2 × P(T ≥ ∣x∣)the alternative says “different from”
Two-tailed, skewed (chi-square, F)p = 2 × min(F(x), 1 − F(x))a two-sided chi-square or F test is needed

For z and t the curve is symmetric, so for a two-tailed test you double the area in one tail to get the p-value. Chi-square and F are skewed and cannot be negative, so the calculator doubles the smaller tail and shows that step in the working.

How to calculate the p value in three steps: first find the test statistic, then pick the tail from your alternative hypothesis, then read the area beyond the statistic from its distribution. This is how you calculate a p value from a test statistic, and the same p value calculation works for z, t, chi-square, F and r (to get the t statistic from your own data, run a t test first). How do you calculate a p value by hand? Use a table to bracket it, then let the calculator give the exact value. To calculate a p-value from a z score, convert the z score to a p value with the standard normal cdf, and for a p value from chi square use the right tail of the chi-square distribution.

Three normal curves showing the shaded area for a left-tailed, a right-tailed and a two-tailed p-value
The tail you choose decides which shaded area counts as at least as extreme as your statistic.

Finding the p-value from a test statistic: worked examples

To find a p-value by hand, you need the test statistic and, for t, chi-square and F, the degrees of freedom. Here is a worked example with a t statistic.

  1. State the hypotheses: H0 says the true mean equals 100, and H1 says it is different (a two-tailed test). Set alpha = 0.05.
  2. A sample of 13 values gives t = 2.50, so df = 13 − 1 = 12.
  3. To calculate a p-value from a t statistic, find the area in the upper tail beyond t = 2.50 on the t distribution with 12 degrees of freedom: P(T ≥ 2.50) = 0.01396.
  4. The test is two-tailed, so double that area: p = 2 × 0.01396 = 0.02792, which rounds to 0.0279.
  5. Test the hypothesis using the p-value approach and compare with alpha: 0.0279 is below 0.05, so reject the null hypothesis. The same result would be a fail to reject at alpha = 0.01, because 0.0279 is above 0.01.

A z-score works the same way, without degrees of freedom. A battery maker claims a mean life of 500 hours with a known standard deviation of 40 hours. A sample of 64 batteries averages 490 hours. The standard error is 40 ÷ √64 = 5, so z = (490 − 500) ÷ 5 = −2.00. How to find the p value from a z score: look up the left-tail area for the z (0.02275 for −2.00); for a positive z, subtract the area from 1 first. The left-tail area is 0.02275, giving a left-tailed p-value of 0.0228. Doubling it gives the two-tailed p-value, 2 × 0.02275 = 0.0455.

t distribution with 12 degrees of freedom and both tails beyond 2.50 shaded, each 0.01396, giving a two-tailed p-value of 0.0279
Worked example: t = 2.50 with df = 12 leaves 0.01396 in each tail, so the two-tailed p-value is 0.0279.

How to use the p-value calculator

  1. Pick the statistic you have: z, t, chi-square, F or Pearson r.
  2. Enter the statistic. Add the degrees of freedom for t (df), chi-square (df), F (df1 for the numerator and df2 for the denominator) or the sample size n for r.
  3. Choose the tail. The defaults are two-tailed for z, t and r, and right-tailed for chi-square and F.
  4. Choose alpha (0.10, 0.05, 0.01 or your own value) and press Calculate.
  5. Read the p-value, the decision and the shaded curve. Copy result copies the result so you can paste it into your notes, and the example buttons load a sample for each statistic.

The calculator accepts a minus sign, decimals with a point and df that are not whole numbers (as long as they are at least 0.5 for t and at least 1 for chi-square and F). If something is out of range, it says what to fix, for example a negative chi-square or an r of exactly 1.

P-value from z, t, chi-square, F and r

Each statistic follows its own distribution under the null hypothesis, so each one needs its own extra input. The table shows what to enter and which tail is the usual choice.

Which statistic needs which extra input, and the usual tail
StatisticAlso neededUsual tailTypical test
znothingtwo-tailedz test, large samples or known σ
tdftwo-tailedt tests, regression slopes
Chi-squaredfright-tailedgoodness of fit, independence
Fdf1 and df2right-tailedANOVA, comparing variances
Pearson rn (df = n − 2)two-tailedtesting a correlation

For a p value from a z score, the cdf is the standard normal distribution, the normal distribution with mean 0 and standard deviation 1. A t score (the t-Student distribution) works the same way but has heavier tails for small samples, so it needs its degrees of freedom. If you need the area for a z with its left, right or middle regions, use the z table; if you need to turn a raw value into z first, use the z score calculator. For the Pearson correlation coefficient r, the calculator converts r to t with t = r × √((n − 2) ÷ (1 − r²)) and then uses the t distribution with n − 2 degrees of freedom. For t critical values at each df, see the t table. An r of 0.62 from 15 pairs gives t = 2.849, df = 13 and a two-tailed p-value of 0.0137.

P-value table and p-value chart

A p value table (or p-value chart) can only bracket a p-value between two printed columns, because it lists critical values for a few probabilities. That is enough to see whether p is above or below 0.05, but not to report it. For a z score use the z table, for a t statistic the t table (a t table p value lookup, or a p value table for a t test, follows the same idea), and for chi-square the chi-square table (a chi-square p-value table works alike). Here you also get exact values between the printed rows.

Chi-square p-value calculator

Switch to Chi-square to turn a chi-square statistic and its degrees of freedom into a p-value. The chi-squared distribution starts at zero and leans to the right, so chi-square tests of goodness of fit and of independence in contingency tables are right-tailed, because a larger statistic means a worse fit to the null hypothesis, so the right tail is the one that counts.

For example, a goodness-of-fit test with 5 categories has df = 5 − 1 = 4. A chi-square statistic of 11.20 gives a right-tail p-value of 0.0244. At alpha = 0.05 you reject the null hypothesis, which agrees with the critical value 9.488 for df = 4. The calculator returns the exact p-value for any statistic and df, while the printed critical values live in the chi-square table linked above.

F-test p-value

For an F statistic, enter both degrees of freedom: df1 for the numerator and df2 for the denominator. The F distribution is right-skewed, so ANOVA and variance-ratio tests use the right tail. An F of 4.50 with df1 = 3 and df2 = 20 gives p = 0.0144, so the result is significant at 0.05 but not at 0.01.

How to interpret a p-value

Compare the p-value with the alpha you chose before looking at the data. When is a p-value significant? When it is at or below that alpha. If p is less than or equal to alpha, reject the null hypothesis. If p is greater than alpha, fail to reject it, which means you do not have enough evidence against it. The p value interpretation is the same for every test, and the p value significance rule is simple: a statistically significant p value is one at or below your alpha. What is a significant p value in practice? Most fields use 0.05. A p value less than 0.05 is the common cut-off, and a p value greater than 0.05 is usually called not statistically significant. There is nothing magic about 0.05, so report the exact value as well. In short, p-value vs alpha is a comparison of the evidence (p) with your threshold (alpha), and the p-value significance threshold is whatever alpha you set in advance, usually 0.05.

How to read a p-value
p-valueA reasonable reading
p > 0.10little or no evidence against the null hypothesis
0.05 < p ≤ 0.10weak evidence, worth another look
0.01 < p ≤ 0.05moderate evidence against the null hypothesis
0.001 < p ≤ 0.01strong evidence against the null hypothesis
p ≤ 0.001very strong evidence against the null hypothesis

What does a p-value tell you? Only how well your data fit the null hypothesis, nothing about the size of an effect. What does the p value represent? The area in the tail or tails beyond your statistic. What does a low p-value mean? The data would be surprising under the null hypothesis, so you have evidence against it. What does a high p-value mean? The data fit the null hypothesis well enough that you cannot reject it. A p-value greater than 0.05 means the same thing in reverse: no evidence strong enough to reject. A p-value of 0.03 does not mean there is a 3% chance the null hypothesis is true. It means that if the null hypothesis were true, a result this extreme would turn up about 3% of the time. A tiny p-value can also come from a very large sample and a trivial difference, so look at the effect size as well, and plan the sample size with the power analysis calculator before you collect data. Can a p-value be 0? In theory it cannot: a very extreme statistic (a right-tailed z of 40, for example) gives a number such as 3.7e-350, which the calculator shows in full instead of rounding to 0, while software that prints 0 has simply run out of digits.

One-tailed vs two-tailed p-value

Choose the tail from your alternative hypothesis, and choose it before you see the data. A two-tailed test (H1: not equal) splits the risk across both ends, so for z and t its p-value is double the one-sided value. Use a one-tailed test only when an effect in the opposite direction is impossible or of no interest. You can also check the other direction: a right-tailed p-value and a left-tailed p-value add up to 1.

Reject or fail to reject the null hypothesis

P-values are one half of hypothesis testing, and the decision line follows one rule. When to reject the null hypothesis? When the p-value falls inside your level of significance, which is the same as the statistic landing in the rejection region. When p ≤ alpha, the calculator says “reject the null hypothesis”. When p > alpha, it says “fail to reject the null hypothesis”. It never says “accept the null”, because a large p-value is not proof that the null hypothesis is true. If you prefer the critical value approach, the z critical value calculator and t critical value page give the cut-off for a chosen alpha, and the two methods always lead to the same decision. The critical value vs p-value question is only a choice of scale: either set the statistic against the critical value, or set the p-value against alpha.

P-value in Excel, R and Python

You can check any result with software. The table uses the examples above.

P-value formulas in Excel, R and Python
TaskExcelRPython (SciPy)
z = −2.00, two-tailed=2*NORM.S.DIST(-2,TRUE)2*pnorm(-2)2*scipy.stats.norm.cdf(-2)
t = 2.50, df 12, two-tailed=T.DIST.2T(2.5,12)2*pt(2.5, 12, lower.tail = FALSE)2*scipy.stats.t.sf(2.5, 12)
Chi-square 11.20, df 4, right=CHISQ.DIST.RT(11.2,4)pchisq(11.2, 4, lower.tail = FALSE)scipy.stats.chi2.sf(11.2, 4)
F = 4.50, df 3 and 20, right=F.DIST.RT(4.5,3,20)pf(4.5, 3, 20, lower.tail = FALSE)scipy.stats.f.sf(4.5, 3, 20)

In Excel the t and F functions already take the tail, so only z needs the doubling. The survival function (sf) is the upper-tail area, and it stays accurate for tiny p-values where 1 minus the cdf would collapse to zero.

How to report a p-value

Report the exact p-value to three decimals, together with the statistic and degrees of freedom, for example t(12) = 2.50, p = .028. Write p < .001 when the value is below 0.001 instead of p = .000, because a p-value is never exactly zero. This calculator never shows p = 0.000 either: for a very large statistic it prints the tiny value in scientific notation. Some papers use p-value asterisks (one star for p < .05, two stars for p < .01, three stars for p < .001), but the exact value is more useful. The calculator adds a report line for you, and it uses the same rule. It starts from a test statistic, so if you only have raw data, first compute the statistic with the matching test, for example a t statistic from a t test or a z statistic for an A/B test of two proportions. Always state the alpha you used and the tail, and add an effect size and a confidence interval when you can.

Common mistakes with p-values

  • Reading p as the probability that the null hypothesis is true.
  • Forgetting to double the one-tail area for a two-tailed test, or doubling it twice.
  • Using the wrong degrees of freedom, for example n instead of n − 1 for a one-sample t, or n instead of n − 2 for r.
  • Switching to a one-tailed test after seeing which direction the data went, or trying several tests until one gives p < 0.05. This p-hacking inflates false positives and is a main reason results fail to replicate.
  • Calling p = 0.051 “no effect” and p = 0.049 “proof” when the evidence is almost the same.
  • Treating a significant p-value as a large or important effect.

P value calculator FAQs

What is a p-value?

It is the chance, assuming the null hypothesis holds, of seeing a test statistic as extreme as yours or more extreme. A small p-value means your data would be unusual under the null hypothesis.

How can I get a p-value from a test statistic?

Choose the matching distribution (z, t, chi-square or F), type in the statistic and its degrees of freedom, select the tail and read off the area beyond it. For a two-tailed z or t test, double the one-tail area.

What is the p-value for a z-score?

In a two-tailed test, p = 2 × (1 − Φ(|z|)), where Φ is the standard normal cdf. A z of −2.00 has a left-tail area of 0.02275, which is the left-tailed p-value (0.0228); doubling it gives the two-tailed p-value, 0.0455.

How do I calculate a p-value from t?

Use the t distribution with the right degrees of freedom. How to find a p-value from a t statistic: with t = 2.50 and df = 12, the upper-tail area is 0.01396, and doubling it gives a two-tailed p-value of 0.0279.

What is the p-value formula?

The formula depends on the tail: p = F(x) for a left tail, p = 1 − F(x) for a right tail, and p = 2 × min(F(x), 1 − F(x)) for a two-tailed test, where F is the cumulative distribution function.

What p-value is significant?

A p-value at or below your alpha is significant. Most studies use alpha = 0.05, so a p value less than 0.05 counts as statistically significant, while stricter fields use 0.01 or 0.001.

What does a p-value less than 0.05 mean?

If the null hypothesis were true, a result this extreme would happen less than 5% of the time, which leads you to reject it at the 5% level.

What does a p-value greater than 0.05 mean?

It means the data are compatible with the null hypothesis, so you fail to reject it. It does not prove the null hypothesis is true.

What is a good p-value?

There is no universally good value. Small values, below your alpha, give evidence against the null hypothesis, but the effect size and study design matter just as much.

Can a p-value be 0?

Not exactly. It can be extremely small, such as 3.7e-350 for a right-tailed z of 40, and this calculator shows it in full instead of rounding it to 0.

One-tailed or two-tailed p-value: which is which?

A one-tailed p-value looks at one direction only, and a two-tailed p-value looks at both. For symmetric z and t tests the two-tailed value is double the one-tailed one.

How can I get a p-value for a chi-square test?

Enter the chi-square statistic and its degrees of freedom and keep the right tail. For 11.20 with df = 4 the p-value is 0.0244.

Is the p-value the same as the critical value?

No. The p-value is an area (a probability) from your data, and the critical value is a cut-off on the test statistic scale for a chosen alpha. Comparing p with alpha and the statistic with the critical value give the same decision.

How can I get a p-value in Excel?

Use T.DIST.2T for a two-tailed t, NORM.S.DIST for z, CHISQ.DIST.RT for chi-square and F.DIST.RT for F. For example =T.DIST.2T(2.5,12) returns 0.0279.

Is this p-value calculator accurate?

Yes. It was checked against R and Python (SciPy) for z, t, chi-square, F and r in all three tails, including very small p-values, and the results agree to six significant digits.

Easy Stat Calc · Results checked against Python, R and Excel formulas · Last updated December 1, 2026 · Methodology