Written and maintained by CASRAI Editorial Board
Last updated
What is the chi-square probability distribution?
The chi-square distribution is the distribution of a sum of squared standard normal variables. In the words of the NIST/SEMATECH e-Handbook of Statistical Methods, it “results when v independent variables with standard normal distributions are squared and summed.” The single parameter v is the degrees of freedom (df). Because every term is squared, the variable can never be negative, and the distribution is skewed to the right, most strongly when df is small.
This page covers the distribution itself: its density, mean, variance, shape and how to read its tail areas. For the tests that use it, see the guide to the chi-square test of independence and goodness of fit.
Formula: the probability density function and every symbol
For x ≥ 0 the density is
f(x) = e−x/2 · xv/2 − 1 / ( 2v/2 · Γ(v/2) )
- x is a value of the variable (x ≥ 0); in a test, it is the computed test statistic.
- v is the shape parameter, the degrees of freedom. Many texts write k instead of v.
- Γ is the gamma function, which extends the factorial to non-integers (for example Γ(2.5) ≈ 1.3293).
- e is Euler’s number, about 2.71828.
The cumulative distribution function is F(x) = γ(v/2, x/2) / Γ(v/2), where γ is the lower incomplete gamma function (NIST). Software evaluates this for you; nobody integrates the density by hand.
Link to the gamma distribution
The density above has the form of a gamma density with shape v/2 and scale 2, so the chi-square distribution is a special case of the gamma distribution. The simplest case is v = 2: the density becomes f(x) = ½e−x/2, an exponential distribution, and the cumulative probability is F(x) = 1 − e−x/2. That gives a hand check: the upper 5% point for 2 df solves e−x/2 = 0.05, so x = −2 ln(0.05) = 5.991, matching the tabled value.
Mean, variance and shape by degrees of freedom
NIST gives these properties as functions of v alone:
| Property | Formula | df = 5 | df = 10 |
|---|---|---|---|
| Mean | v | 5 | 10 |
| Variance | 2v (standard deviation √(2v)) | 10 (SD 3.162) | 20 (SD 4.472) |
| Mode (v > 2) | v − 2 | 3 | 8 |
| Skewness | 21.5 / √v | 1.265 | 0.894 |
Read the skewness row as the shape story. With 1 or 2 df the density falls from its left edge; from 3 df upward a hump appears at v − 2 and the right tail stretches beyond it. As df grows the skewness shrinks as 1/√v, so the curve moves toward a symmetric bell, but slowly: even at 10 df the skewness is still 0.894. This is why a normal approximation is poor for small df, and why the tests use chi-square tables or software rather than z tables.
Additivity
If two independent chi-square variables have v1 and v2 degrees of freedom, their sum is chi-square with v1 + v2 df. This follows directly from the definition: summing v1 squared standard normals and v2 more gives v1 + v2 of them. It is why the df of a combined statistic is the sum of the df of its parts.
Worked example with the arithmetic shown
Part A: the density at one point. Take v = 5 and x = 3 (the mode).
- v/2 = 2.5, so the exponent of x is 2.5 − 1 = 1.5.
- Numerator: e−1.5 × 31.5 = 0.22313 × 5.19615 = 1.15944.
- Denominator: 22.5 × Γ(2.5) = 5.65685 × 1.32934 = 7.51985.
- f(3) = 1.15944 / 7.51985 = 0.1542.
Part B: a tail probability. Suppose a test with 5 df gives a statistic of 11.5. Compare it to the tabled upper-tail value for α = .05 and 5 df, which is 11.070 (NIST). Because 11.5 > 11.070, the statistic lies in the rejection region at the .05 level. Software gives the exact upper-tail area: P(X ≥ 11.5) = .042, which is below .05, consistent with the table. A statistic of 7.5 on the same 5 df gives an upper-tail area of .186, well above .05, and would not be rejected.
Interpretation: how to read the table and the p-value
The distribution is not symmetric, so NIST provides separate tables for the upper and lower tails. In the NIST table the columns are P(X < critical value), so a test at α = .05 uses the 0.95 column. A one-sided upper-tail test rejects H0 when the statistic exceeds the tabled upper-tail value. The rejection region and the critical value procedure are covered in their own guides.
| df | Critical value, α = .05 | Critical value, α = .01 |
|---|---|---|
| 1 | 3.841 | 6.635 |
| 2 | 5.991 | 9.210 |
| 5 | 11.070 | 15.086 |
| 10 | 18.307 | 23.209 |
Values are from the NIST/SEMATECH table of upper-tail critical values. How to read the result:
| If the statistic is… | Then… |
|---|---|
| Above the upper-tail critical value for your α and df | The upper-tail area is smaller than α; reject H0 in a one-sided upper-tail test |
| At or below that critical value | The upper-tail area is at least α; do not reject H0 |
| Near the df value (the mean) | Typical of what chance alone produces, since the mean equals v |
A related table of the F distribution, which is built from ratios of chi-square variables, is in the F table guide. For the meaning of the resulting probability, see the dictionary entry on the p-value.
Assumptions and common mistakes
- The definition needs independence. The sum-of-squares result holds for independent standard normal variables. In a test, the chi-square reference distribution is a large-sample approximation, so check the conditions of the specific test.
- Using the wrong tail. Most tests reject for large statistics, so use the upper tail. Mixing up the upper and lower tables, or the 0.05 and 0.95 columns, is the most common table error.
- Confusing df with sample size. The parameter v is not n; its value depends on the test.
- Expecting symmetry. The mean is v but the mode is v − 2, so the most likely value sits left of the mean, and a statistic above the mean is not automatically unusual.
- Forcing a normal approximation at small df. The skewness table above shows why this is unreliable.
How to report a chi-square result (APA example)
Report the degrees of freedom in parentheses, the statistic to two decimals, and the exact p-value. Using the hypothetical result from Part B (and an illustrative sample size):
The association was statistically significant, χ²(5, N = 120) = 11.50, p = .042.
In APA style, p is italicised and a leading zero is omitted because p cannot exceed 1. Report the test, not just the distribution, as described in the chi-square test guide.
How to calculate it in Excel, R or Python
Each snippet reproduces the checks above: the upper-tail area for a statistic of 11.5 on 5 df (.042) and the 5% critical value for 5 df (11.070).
Excel
=CHISQ.DIST.RT(11.5, 5) // upper-tail area, 0.042
=CHISQ.INV.RT(0.05, 5) // critical value, 11.070
=CHISQ.DIST(3, 5, FALSE) // density at x = 3, 0.1542
R
pchisq(11.5, df = 5, lower.tail = FALSE) # 0.042
qchisq(0.95, df = 5) # 11.070
dchisq(3, df = 5) # 0.1542
Python (SciPy)
from scipy.stats import chi2
chi2.sf(11.5, 5) # 0.042
chi2.ppf(0.95, 5) # 11.070
chi2.pdf(3, 5) # 0.1542
Frequently asked questions
What does the chi-square distribution describe?
It describes the sum of squares of independent standard normal variables, and it is the reference distribution for chi-square tests, likelihood-ratio tests and confidence intervals for a normal variance.
What is the mean and variance of a chi-square distribution?
The mean is v and the variance is 2v, where v is the degrees of freedom.
Why is the chi-square distribution skewed?
Squaring removes negative values, so the variable is bounded at zero with a long right tail. The skewness is 21.5/√v, which falls as df rises.
Is the chi-square distribution a gamma distribution?
Yes. It is a gamma distribution with shape v/2 and scale 2, and with 2 df it is the exponential distribution.
Should I use the upper or lower tail?
Use the upper tail for the usual chi-square tests, where large statistics count against H0. For the NIST table, use the 0.95 column for α = .05.
Sources
- NIST/SEMATECH e-Handbook of Statistical Methods, “Chi-Square Distribution”: itl.nist.gov/div898/handbook/eda/section3/eda3666.htm (checked 2026-10-29).
- NIST/SEMATECH e-Handbook of Statistical Methods, “Critical Values of the Chi-Square Distribution”: itl.nist.gov/div898/handbook/eda/section3/eda3674.htm (checked 2026-10-29).
- Wikipedia, “Chi-squared distribution” (secondary overview used for the gamma relation and uses in testing): en.wikipedia.org/wiki/Chi-squared_distribution (checked 2026-10-29).








