P-Value & Probability Calculator

Written by the StepSolvers Team  │  Reviewed by a Math Educator  │  Last updated July 2026

The p-value calculator finds the p-value from a z-score or a t-score, for either a one-tailed or a two-tailed test — showing every step of the working, including the test statistic and the significance decision. Enter your test statistic below and get a complete step-by-step result instantly.

This free p-value calculator clearly labels one-tailed and two-tailed results side by side, so there is no confusion about which number applies to your hypothesis test. It supports both the z-distribution and the t-distribution. No signup required.

Step-by-Step Solution

    P-Value:

    What Is a P-Value?

    A p-value is the probability of getting a result at least as extreme as the one observed, assuming the null hypothesis is true. A small p-value means the observed result would be unlikely if there were really no effect — which is evidence against the null hypothesis. A p-value does not tell you the probability that the null hypothesis is true; it only tells you how surprising your data would be if it were. Laerd Statistics covers the full reasoning behind hypothesis testing if you want to go deeper than the summary below.

    Null Hypothesis vs Alternative Hypothesis

    TermMeaning
    Null hypothesis (H₀)The default assumption that there is no effect or no difference. The p-value is calculated assuming this is true.
    Alternative hypothesis (H₁)The claim you're testing for — that there is an effect or a difference. A small p-value gives evidence for this instead.
    Significance level (α)The threshold you decide in advance, commonly 0.05. If the p-value is below α, the result is called statistically significant.

    P-Value Formula Explained

    From a Z-Score (Known Population Standard Deviation)

    When the population standard deviation is known, first calculate a z-score, then convert it to a p-value using the standard normal distribution. The Standard Deviation Calculator can help you find that population standard deviation if you don't already have it.

    z = (x̄ − μ) / (σ / √n) Where: x̄ = sample mean μ = population mean σ = population standard deviation n = sample size One-tailed p-value = the area beyond z in one direction of the standard normal curve Two-tailed p-value = the combined area beyond +z and beyond −z (double the one-tailed value)

    From a T-Score (Unknown Population Standard Deviation)

    When the population standard deviation is not known — the more common real-world case — use the sample standard deviation and the t-distribution instead.

    t = (x̄ − μ) / (s / √n) Where: s = sample standard deviation Degrees of freedom (df) = n − 1 The t-distribution is wider than the normal distribution for small samples, which is why the same t-value can produce a larger p-value than the equivalent z-value.

    How to Use This P-Value Calculator

    1. Choose your test type: Z-Test (population standard deviation known) or T-Test (population standard deviation unknown).
    2. Enter your sample mean, the comparison value, the standard deviation, and the sample size.
    3. Select One-Tailed or Two-Tailed — the calculator clearly labels both results so you always know which number to report.
    4. Click Calculate. The test statistic (z or t) and the resulting p-value appear instantly, along with the significance decision at α = 0.05.
    5. Use the bell curve diagram to see exactly which area of the distribution the p-value represents.
    6. Click Reset to clear all inputs and start a new calculation.

    Worked Examples — Step by Step

    Example 1: Calculate a Z-Score and Its P-Value

    A population has a mean IQ of 100 and a standard deviation of 15. A sample of 25 people has a mean IQ of 106. Test whether this sample differs significantly from the population.

    1. Write the known values: μ = 100, σ = 15, x̄ = 106, n = 25
    2. Write the z-score formula: z = (x̄ − μ) / (σ / √n)
    3. Calculate the standard error: 15 / √25 = 15 / 5 = 3
    4. Substitute: z = (106 − 100) / 3 = 6 / 3
    5. Calculate: z = 2
    6. Look up the two-tailed p-value for z = 2 using the standard normal distribution: p ≈ 0.0455
    z = 2 │ Two-tailed p-value ≈ 0.0455

    Example 2: One-Tailed vs Two-Tailed — Same Z-Score, Different Answer

    Using the same z-score of 2 from Example 1, compare the one-tailed and two-tailed p-values directly. This is the exact distinction that gets confused when a calculator doesn't label its tabs clearly.

    +z −z Shaded regions = tail areas
    1. Start with the test statistic: z = 2
    2. One-tailed p-value: the area in a single tail beyond z = 2 → p ≈ 0.0228
    3. Two-tailed p-value: double the one-tailed area, since you're checking both directions → p ≈ 0.0228 × 2 = 0.0456
    4. Compare to α = 0.05: both the one-tailed (0.0228) and two-tailed (0.0456) results are below 0.05 — significant either way, but the exact numbers differ
    One-tailed p ≈ 0.0228 │ Two-tailed p ≈ 0.0456 (always use the tail type that matches your hypothesis)

    Example 3: Interpreting a P-Value Against the Significance Level

    A study reports a p-value of 0.03. The significance level was set in advance at α = 0.05. Decide whether the result is statistically significant.

    1. Write the p-value: p = 0.03
    2. Write the significance level: α = 0.05
    3. Compare: is p less than α? 0.03 < 0.05 → yes
    4. Decision: reject the null hypothesis — the result is statistically significant
    p = 0.03 < 0.05 → statistically significant, reject H₀

    Contrast case: if the study had instead reported p = 0.12, then 0.12 > 0.05, so you would fail to reject the null hypothesis — the result would not be considered statistically significant at the 0.05 level.

    Example 4: P-Value from a T-Score (Small Sample)

    A small sample of 10 measurements produces a t-statistic of 2.5. Find the approximate two-tailed p-value.

    1. Write the known values: t = 2.5, n = 10
    2. Calculate degrees of freedom: df = n − 1 = 10 − 1 = 9
    3. Look up t = 2.5 with df = 9 in the t-distribution: two-tailed p ≈ 0.034
    4. Compare to α = 0.05: 0.034 < 0.05 → statistically significant
    t = 2.5, df = 9 │ Two-tailed p ≈ 0.034 → significant

    When to Use a P-Value Calculator

    P-values are the standard way to report whether a result is likely due to chance. Common uses include:

    One-Tailed vs Two-Tailed Tests — Choosing the Right One

    Choosing between a one-tailed and two-tailed test depends on your hypothesis — not on which one gives a smaller p-value. This choice must be made before looking at your data.

    Test typeWhen to use it
    Two-tailed testUse when your hypothesis only claims there is a difference, in either direction. Example: "the new process produces a different average than the old one."
    One-tailed test (right-tailed)Use when your hypothesis claims the result is specifically higher. Example: "the new process produces a higher average than the old one."
    One-tailed test (left-tailed)Use when your hypothesis claims the result is specifically lower. Example: "the new process produces a lower average than the old one."

    A common mistake is switching from a two-tailed to a one-tailed test after seeing the data, just to get a smaller p-value. This inflates the chance of a false positive and is considered poor statistical practice. Decide the tail direction based on your hypothesis, before you calculate anything.

    Common Mistakes When Working with P-Values

    • Treating a high p-value as proof the null hypothesis is true: a p-value above 0.05 only means there wasn't enough evidence to reject the null hypothesis — it doesn't prove there is no effect.
    • Using a z-test when the population standard deviation is unknown: this is one of the most common test-selection errors — use a t-test instead whenever the population standard deviation must be estimated from the sample.
    • Confusing statistical significance with practical significance: a large enough sample can produce a very small p-value even for a tiny, real-world-meaningless effect. Always look at the size of the effect, not just the p-value.
    • Rounding the test statistic too early: rounding a z-score or t-score before looking up the p-value can shift the result across a common threshold like 0.05 — keep full precision until the final step.

    Frequently Asked Questions

    What is a p-value?
    A p-value is the probability of observing a result at least as extreme as your data, assuming the null hypothesis is true. A small p-value suggests your result would be unlikely under the null hypothesis, which counts as evidence against it. A p-value does not tell you the probability that the null hypothesis itself is true.
    How do you calculate a p-value?
    First calculate a test statistic — a z-score if the population standard deviation is known, or a t-score if it isn't. Then look up that test statistic in the standard normal or t-distribution to find the area beyond it, which is the p-value. For example, a z-score of 2 gives a two-tailed p-value of about 0.0455.
    What does it mean if the p-value is less than 0.05?
    A p-value below 0.05 (the most common significance level) means the result is considered statistically significant — the observed effect would be unlikely to happen by chance alone if the null hypothesis were true. This leads to rejecting the null hypothesis in favor of the alternative hypothesis.
    What is the difference between a one-tailed and two-tailed p-value?
    A two-tailed p-value checks for a difference in either direction and is the sum of both tail areas. A one-tailed p-value checks for a difference in only one specific direction and uses just one tail area — which is why it is always smaller than the two-tailed value for the same test statistic. Choose based on your hypothesis, not to get a smaller number.
    What is the difference between a z-test and a t-test?
    A z-test is used when the population standard deviation is known and generally works best with larger samples. A t-test is used when the population standard deviation is unknown and must be estimated from the sample, which is the more common situation in real research. The t-distribution is wider than the normal distribution, especially for small samples.
    What is the null hypothesis?
    The null hypothesis is the default assumption that there is no effect or no difference between groups. Every p-value is calculated by assuming the null hypothesis is true, then measuring how surprising the observed data would be under that assumption. A small p-value is evidence against the null hypothesis.
    Can a p-value be exactly 0?
    In practice, a calculated p-value is never exactly zero, though it can be extremely small and get rounded to 0.000 or reported as p < 0.001. A p-value represents a probability, and a true probability of exactly zero would mean the observed result was mathematically impossible under the null hypothesis, which is not how real data works.
    What is a good significance level to use?
    The most common significance level is 0.05, meaning a 5% chance of a false positive is considered acceptable. Some fields use stricter thresholds like 0.01 for higher-stakes research, while exploratory studies sometimes use a more lenient 0.10. The significance level should always be chosen before collecting data, not after seeing the results.

    Related Calculators

    Standard Deviation Calculator
    Find the standard deviation of a dataset — the value that feeds directly into every z-score and t-score calculation.
    Average Calculator
    Find the mean of a dataset — the sample mean used as the starting point for a z-test or t-test.
    Percentage Calculator
    Convert a p-value or confidence level into a percentage, or calculate percent increase, decrease, and percent error.

    Z-Score Calculator

    Enter a raw value, population mean, and standard deviation to find the z-score and percentile rank.

    P-Value from T-Score

    Enter a t-statistic and degrees of freedom to find the p-value.