P Value: Meaning, Formula, Examples & Complete Guide
A p value helps you judge how unusual your data would be if the null hypothesis were true. This guide explains the meaning, calculation, examples, common mistakes, and better ways to report results.
P Value: Meaning, Formula, Interpretation, and Complete Guide
A practical guide to p values, hypothesis testing, formulas, worked examples, significance and common mistakes.

The p value, or probability value, is one of the most commonly used numbers in statistics. It helps researchers judge how unusual their data would be if a chosen null hypothesis and statistical model were correct.
You will see p values in medical studies, psychology, A/B testing, business experiments, manufacturing, education, economics, and many other fields. A small p value means the observed result would be unusual under the null model. It does not tell you the probability that the null hypothesis itself is true.
For example, if a website experiment produces p = 0.03, that does not mean there is a 3% chance that the difference happened by accident. It means that, under the null model, a result at least as extreme as the observed result would occur about 3% of the time.
What Is a P Value?
A p value is the probability of obtaining a test statistic at least as extreme as the one observed, assuming the null hypothesis and the statistical model are correct.
In simple terms, it asks: If there were really no effect or no difference, how unusual would my result be?
The p value always falls between 0 and 1. A small p value means the data are less compatible with the null hypothesis. A larger p value means the data are not especially unusual under the null model, but it does not prove the null hypothesis is true.

What Does the P in P Value Mean?
The “p” stands for probability. The p value is calculated from a probability distribution under a specified null hypothesis.
A p value close to zero means the observed result would be relatively unusual under that model. A p value closer to one means the result is not unusual under the model. Neither result proves a hypothesis with certainty.
Hypothesis Testing
A statistical hypothesis test usually starts with two competing statements. The null hypothesis, written H₀, normally represents no difference, no association, or a specific reference value. The alternative hypothesis, written H₁ or Hₐ, represents the possibility that the population differs from that null value.
For example, a researcher testing a new teaching method might use H₀: the new method does not change the average score, and H₁: the new method changes the average score.
The researcher then calculates a test statistic and a p value. The p value measures how unusual the observed test statistic would be under H₀.
What a P Value Actually Means
Suppose a statistical test gives p = 0.03. A careful interpretation is: assuming H₀ and the model assumptions are correct, there is a 3% probability of obtaining a test statistic at least as extreme as the one observed.
It is important to avoid turning that statement around. The p value is a probability about possible data under H₀, not a probability that H₀ is true.
| Incorrect interpretation | Why it is wrong |
|---|---|
| “There is a 3% chance H₀ is true.” | The p value describes the data under H₀, not the probability of H₀. |
| “There is a 97% chance H₁ is true.” | A standard p value does not assign probabilities to hypotheses. |
| “There is a 3% chance the result is due to chance.” | Random variation is already part of the null model. |
| “The result will replicate 97% of the time.” | Replication depends on sample size, effect size, design, bias, and other factors. |
| “The effect is important.” | Statistical significance does not measure practical importance. |
What Is a P Value Used For?
The main purpose of a p value is to help evaluate evidence against a null hypothesis. It is useful when researchers want to know whether an observed difference, association, or effect is difficult to explain by ordinary sampling variation under H₀.
| Question | Possible test |
|---|---|
| Does a new treatment differ from a control? | t-test, regression, or another clinical model |
| Do several group means differ? | ANOVA |
| Did a website change conversion rate? | Proportion test |
| Is a coin fair? | Binomial test |
| Are two categorical variables related? | Chi-square test |
| Is a regression coefficient different from zero? | Regression hypothesis test |
P Value Formula
There is no single arithmetic formula that calculates every p value. The exact calculation depends on the statistical test, the test statistic, the reference distribution under H₀, and whether the test is one-sided or two-sided.
The general idea is: p = P(test statistic at least as extreme as the observed statistic | H₀).
For a right-tailed test: p = P(T ≥ t_obs | H₀). For a left-tailed test: p = P(T ≤ t_obs | H₀). For many symmetric two-sided tests: p = 2 × P(T ≥ |t_obs| | H₀).
One-Proportion Z-Test Formula
A simple way to see how a test statistic is built is the one-proportion z-test:
z = (p̂ − p₀) / √[p₀(1 − p₀) / n]
| Symbol | Meaning |
|---|---|
| p̂ | Observed sample proportion |
| p₀ | Proportion assumed under H₀ |
| n | Sample size |
| z | Standardized test statistic |
How Is a P Value Calculated?
Most p values are calculated in three broad stages. First, define the null and alternative hypotheses. Second, calculate a test statistic that measures how far the observed result is from what H₀ predicts. Third, use the appropriate probability distribution to find how often a value at least that extreme would occur under H₀.
For a z-test, the reference distribution is the standard normal distribution. A t-test uses a t-distribution, ANOVA uses an F-distribution, chi-square tests use a chi-square distribution, and exact binomial tests use the binomial distribution.

Animated illustration: as the observed test statistic moves farther into the tails, the two-sided p value becomes smaller.
P Value Example: Is a Coin Fair?
Suppose a researcher flips a coin 100 times and observes 60 heads. Under H₀, the probability of heads is 0.50. The observed proportion is 0.60.
Using a normal approximation, the standard error under H₀ is √[0.50 × 0.50 / 100] = 0.05. The z-statistic is (0.60 − 0.50) / 0.05 = 2.00. A two-sided normal-approximation p value is about 0.0456.
An exact binomial test gives a slightly different p value because it works directly with the discrete binomial probabilities. Both calculations illustrate the same idea: unusually high or low counts contribute to the p value.

P Value and Significance Level
The significance level, usually written α, is a decision threshold selected before interpreting the results. The p value is calculated from the observed data afterward.
A common choice is α = 0.05. If p ≤ α, the result is conventionally called statistically significant at that level and H₀ is rejected. If p > α, we do not reject H₀.
“Do not reject” is better wording than “accept H₀” because a non-significant result may reflect limited precision rather than proof that the null hypothesis is exactly true.
| Measure | When determined | Meaning |
|---|---|---|
| Alpha (α) | Before interpreting results | Decision threshold for the testing procedure |
| P value | After collecting data | Tail probability under H₀ |
| Effect estimate | After collecting data | Size and direction of the observed effect |
| Confidence interval | After collecting data | Range of effect sizes compatible with the data under the model |

Why Is 0.05 Commonly Used?
The 0.05 threshold became a widely used convention, but it is not a law of nature. Other thresholds such as 0.10, 0.01, or 0.001 may be reasonable depending on the consequences of false positives, the number of tests, the research field, and the study design.
The threshold should be chosen for the problem rather than treated as a universal definition of truth.
What Does a P Value of 0.05 Mean?
If p = 0.05, then under H₀ and the model assumptions, results at least as extreme as the observed result would occur about 5% of the time.
It does not mean there is a 5% probability that H₀ is true, and it does not mean there is a 95% probability that the research hypothesis is correct.
What Do P = 0.01 and P = 0.001 Mean?
A p value of 0.01 means results at least this extreme would occur about 1% of the time under the null model. A p value of 0.001 means roughly 1 time in 1,000 under that model.
Smaller p values generally indicate stronger incompatibility with H₀, but they still do not measure how large or useful the effect is.
P Value Interpretation
P values are often split into “significant” and “not significant,” but evidence does not suddenly change at 0.05. For example, p = 0.049 and p = 0.051 are very similar results even though conventional labels differ.
A better interpretation considers the p value together with sample size, effect size, confidence intervals, study design, measurement quality, and possible bias.
| P value pattern | General interpretation |
|---|---|
| Very small | The data are difficult to explain under H₀. |
| Around the chosen α | Borderline evidence that deserves careful interpretation. |
| Moderately large | The data do not provide strong evidence against H₀. |
| Very large | The data are compatible with H₀, but H₀ is not proven. |
One-Tailed vs. Two-Tailed P Values
A one-tailed test looks for an effect in one specified direction. For example, H₁: p > 0.50. A two-tailed test looks for departures in either direction, such as H₁: p ≠ 0.50.
The direction should be chosen from the research question before looking at the result. Choosing a one-sided test after seeing the data can make the evidence look stronger than it really is.
P Value vs. Confidence Interval
A p value helps answer how compatible the data are with a specific null hypothesis. A confidence interval helps show the range of effect sizes that remain reasonably compatible with the data under the model.
For example, a treatment could have p = 0.01 but an estimated effect of only 2 units. The p value addresses evidence against a zero-effect null. The effect estimate and confidence interval tell you whether the size of the effect is meaningful and how uncertain the estimate is.
Statistical Significance vs. Practical Significance
A statistically significant result is not automatically an important result. A huge sample may detect a tiny difference that has almost no practical value.
This is why effect size, confidence intervals, costs, risks, and the real-world decision should be considered alongside the p value.
Standard Error and Sample Size
Sample size can strongly influence p values. As sample size grows, standard error usually becomes smaller, so the same observed difference can produce a larger test statistic and a smaller p value.
This does not mean larger samples create bigger effects. They make estimates more precise, which can make smaller departures from H₀ easier to detect.

Sample Size and Magnitude of Effect
The p value depends on both the size of the observed effect and the amount of uncertainty. Larger effects are usually easier to distinguish from random variation. Larger samples usually reduce uncertainty.
This is why a very large dataset can produce a tiny p value for a small effect, while a small study can miss an effect that might still matter in practice.
Common P Value Misconceptions
The most damaging mistakes come from giving the p value a meaning it does not have.
| Common belief | Correct interpretation |
|---|---|
| p = 0.03 means H₀ has a 3% chance of being true | No. It describes the probability of data at least this extreme under H₀. |
| p > 0.05 proves H₀ | No. It means there is not enough evidence to reject H₀ at that threshold. |
| p < 0.05 proves H₁ | No. It provides evidence against H₀ under the model. |
| Smaller p always means a bigger effect | No. Sample size and variability strongly affect p values. |
| Statistical significance means practical importance | No. Effect size and context are separate questions. |
| 0.05 is a universal scientific rule | No. It is a convention. |
A/B Testing and P Values
P values are widely used in digital experiments. Suppose Version A produces 42 purchases from 1,000 visitors and Version B produces 56 purchases from 1,000 visitors. The observed conversion rates are 4.2% and 5.6%.
A two-proportion test asks whether a difference at least this large could reasonably occur if the true conversion rates were equal. In a worked example, the two-sided p value is about 0.147, so the experiment does not provide strong evidence of a real difference at the 0.05 threshold.
That does not prove the versions are identical. The experiment may simply be too imprecise to separate the observed difference from sampling noise.
P Values in Medical Research
Medical studies often use p values to evaluate treatment effects, risk factors, and differences between patient groups. But clinical decisions should not depend on p values alone.
A treatment can produce p < 0.001 while changing an outcome by an amount that is too small to matter to patients. A small pilot study can also produce p = 0.07 for a potentially important effect because the estimate is imprecise.
Clinical interpretation therefore needs effect size, confidence intervals, study quality, harms, benefits, and the broader evidence base.
Multiple Comparisons and P Values
When many hypotheses are tested, some small p values can appear purely through random variation. This is why multiple-testing methods exist.
Common approaches include Bonferroni and Holm adjustments, while specialized designs may use Dunnett or false-discovery-rate procedures. The right method depends on how many tests are planned and what family of conclusions the analysis is meant to support.
Type I and Type II Errors
A Type I error occurs when H₀ is rejected even though it is true. A Type II error occurs when a meaningful alternative exists but the test fails to detect it.
Alpha controls the long-run Type I error rate for the planned testing procedure under its assumptions. Statistical power describes the probability of detecting a specified effect when it is truly present.
Making alpha extremely small reduces false positives but can also make real effects harder to detect unless the study has enough information.
Where P Values Are Used
P values appear wherever researchers compare data with a statistical null model.
| Field | Example |
|---|---|
| Clinical research | Comparing treatment and placebo outcomes |
| Psychology | Testing behavioral differences |
| Business | Evaluating pricing or marketing experiments |
| A/B testing | Comparing conversion rates |
| Manufacturing | Testing whether a process or defect rate changed |
| Education | Comparing learning outcomes |
| Economics | Testing model coefficients and relationships |
| Genetics | Testing large numbers of associations |
| Quality control | Checking whether a process has shifted |
How to Report a P Value
When practical, report the actual p value instead of only writing “p < 0.05.” For example: “The treatment group had a lower average recovery time, t(98) = 2.91, p = 0.004.”
A stronger report also gives the effect estimate, confidence interval, sample size, test used, and any important model assumptions.

What Is a Good P Value?
There is no universal “good” p value. Researchers should not design an analysis around the goal of obtaining p < 0.05. The goal is to run a sound study and report the evidence honestly.
A p value of 0.20 from a careful study can be more informative than p = 0.001 from a biased or poorly designed study.
Is a Smaller P Value Always Better?
Not necessarily. A smaller p value usually means greater incompatibility with H₀ under the same model, but it does not automatically mean a larger effect, better research, greater practical importance, or a more accurate model.
Can the P Value Be Zero?
Statistical software may display p = 0.000 because the value is smaller than the number of decimal places shown. It normally does not mean the true calculated probability is exactly zero.
For example, a value of 0.00003 may be displayed as 0.000. A clearer report is usually p < 0.001.
Frequently Asked Questions About P Values
-
What is a p value in simple terms?
It tells you how unusual your test result would be if the null hypothesis and the statistical model were correct.
-
What does p < 0.05 mean?
If α = 0.05 was chosen in advance, p < 0.05 means the result meets that conventional significance threshold. It does not mean H₀ has less than a 5% chance of being true.
-
Is p = 0.05 statistically significant?
If the rule is p ≤ 0.05, it sits at the decision boundary. Results close to the threshold should still be interpreted with context rather than as a sharp scientific divide.
-
What does a high p value mean?
The observed data are not particularly unusual under H₀. It does not prove H₀.
-
What does a low p value mean?
The observed data would be relatively unusual under H₀, providing evidence against that null model.
-
What is the difference between p value and alpha?
Alpha is a decision threshold chosen before interpreting results. The p value is calculated from the observed data.
-
Does p > 0.05 mean there is no effect?
No. It means the data did not provide enough evidence to reject H₀ at the chosen threshold. Limited sample size or noisy measurements may be part of the reason.
-
Does a p value show effect size?
No. Effect size describes magnitude. The p value addresses compatibility with a null hypothesis.
-
Why are p values controversial?
Problems arise when p values are treated as a complete measure of evidence or reduced to a rigid 0.05 pass/fail rule. Good interpretation also uses effect sizes, confidence intervals, design, and context.
Final Thoughts
The central meaning of a p value is simple: it measures how unusual the observed test statistic, or something more extreme, would be if the null hypothesis and statistical model were correct.
A small p value can provide evidence against H₀. A large p value means the data do not provide strong evidence against H₀. Neither result proves a hypothesis with certainty.
The biggest mistake is treating p < 0.05 as the complete answer to a research question. Good statistical interpretation also considers effect size, confidence intervals, sample size, study design, statistical power, bias, assumptions, and practical importance.
Sources Consulted
