Chi-Square Calculator

Independence • Goodness-of-fit • Critical χ²

Settings

α
α is optional. Used for critical χ² (right-tail) and decision.
Quick summary
Pick a mode and enter values.
Rows Cols
Enter counts table (observed). We compute expected counts and χ².
Observed counts
Tip: you can paste a row like: 10 12 8 into a row’s first cell.

Use counts, not percentages, and check that expected counts are large enough (often at least 5).

Results

χ² statistic
Degrees of freedom (df)
p-value (right tail)
p = P(Χ² ≥ χ²_obs)
Critical χ² (α)
Right-tail: P(Χ² ≥ χ²_crit)=α
Decision
Reject H₀ if p ≤ α (α default 0.05).
Total N
Updating…

Action

Hard reset: cancels pending updates and clears everything on the first click.

Use this Chi-Square Calculator for goodness-of-fit tests, tests of independence, or right-tail chi-square distribution calculations.

Calculation Method

The chi-square statistic is:

χ² = Σ[(O − E)² ÷ E]

Where O is the observed count and E is the expected count.

For a test of independence:

Expected count = row total × column total ÷ grand total

df = (rows − 1) × (columns − 1)

For a goodness-of-fit test with fully specified expected probabilities:

Expected count = total sample size × expected proportion

df = number of categories − 1

Example

Suppose three categories have observed counts of 20, 30, and 50, while equal frequencies are expected.

Total observations = 100, so each expected count is approximately 33.33.

χ² ≈ (20−33.33)²/33.33 + (30−33.33)²/33.33 + (50−33.33)²/33.33

χ² ≈ 14.0

With three categories:

df = 3 − 1 = 2

Important Note

Chi-square tests use counts, not percentages alone. Observations should be appropriately independent, and expected counts must be sufficiently large for the chi-square approximation to be reliable. A significant result does not prove causation.

Sources

View Sponsored Offers →

Related Tools

t-statistic Calculator

Use our t-Statistic Calculator to compute the t value, degrees of freedom, and standard error for one-sample, two-sample, Welch, pooled, or paired t-tests.

Z-score Calculator

Use our Z-Score Calculator to standardize a value or sample mean, convert percentile to z, convert z to percentile, and view left-tail and right-tail probabilities.

p-value Calculator

Use our P-value Calculator to calculate one-tailed or two-tailed p-values for Z, t, chi-square, and F test statistics.

IQ PERCENTILE CALCULATOR

Use our IQ Percentile Calculator to convert an IQ score into percentile rank, percent above, and percent below using SD 15 or SD 16 normal-distribution scales.

Z-test Calculator

Use our Z-Test Calculator to compute z statistic, p-value, standard error, and critical z for one-sample or two-sample mean tests when sigma is known.

Outlier Calculator (Tukey Fences)

Use our Outlier Calculator to find low and high outliers with Tukey fences and the IQR method. Get Q1, Q3, IQR, fences, counts, and sorted data fast.

Confidence Interval Calculator

Use our Confidence Interval Calculator to find confidence intervals for a mean or proportion with standard error, critical value, margin of error, and lower and upper bounds.

Percentile Calculator

Use our Percentile Calculator to find percentile values from a data set with nearest rank or linear interpolation. Supports raw numbers and value:count input.

Standard Deviation Calculator

Use our Standard Deviation Calculator to find sample or population standard deviation from a data set. Get variance, mean, range, and sorted values fast.