Skip to content
ToolUlkaa Tool
All tools

Statistics

Statistics CalculatorRandom Number GeneratorStandard Deviation CalculatorZ-Score CalculatorProbability CalculatorPermutation and Combination CalculatorP-Value CalculatorT-Test CalculatorConfidence Interval CalculatorSample Size CalculatorChi-Square CalculatorCorrelation Coefficient CalculatorLinear Regression CalculatorANOVA CalculatorProbability Distribution Calculator

Categories

AcademicTextMathematicsStatisticsMachine LearningAIData ScienceFile
All tools
Statistics

Chi-Square Goodness of Fit Calculator

Type the observed counts and see whether they match what you expected.

Test
6 values read. Separate with commas, spaces or new lines.
Expected values
Usually 0. Each estimated parameter removes one degree of freedom.
Significance level (α)

Goodness-of-fit test

χ² = 13.4, p = 0.020
Degrees of freedom
5
Critical value
11.07
Total count
60

p = 0.020 < α = 0.05, so reject H0: the data follow the expected distribution. There is evidence that the observed counts differ from the expected counts. Category 6 contributes the most to the statistic (10 of 13.4).

Chi-square distribution and rejection region

Chi-square distribution and rejection regionChi-square distribution and rejection region. The right tail is shaded. The χ² is 13.4.0246810121416χ² (df = 5)χ² = 13.4

The shaded right tail is the rejection region (area 0.05). The dashed line is your chi-square statistic.

Expected counts and contributions

Expected counts (E)

101010101010

Contribution of each cell, (O − E)² / E

2.50.40.10.4010

The contributions add up to the chi-square statistic. The largest ones show which cells differ most from what was expected.

Step-by-step working

  1. 1Hypotheses
    H0: the data follow the expected distributionH_0:\ \text{the data follow the expected distribution}H0​: the data follow the expected distribution
    ↓
    H1: they do notH_1:\ \text{they do not}H1​: they do not
  2. 2Expected counts
    Ei=Nk=606E_i = \dfrac{N}{k} = \dfrac{60}{6}Ei​=kN​=660​
    ↓
    10, 10, 10, 10, 10, 1010,\ 10,\ 10,\ 10,\ 10,\ 1010, 10, 10, 10, 10, 10
  3. 3Chi-square statistic
    χ2=∑(Oi−Ei)2Ei\chi^2 = \sum \dfrac{(O_i - E_i)^2}{E_i}χ2=∑Ei​(Oi​−Ei​)2​
    ↓
    (5−10)210+(8−10)210+(9−10)210+(8−10)210+(10−10)210+(20−10)210=13.4\dfrac{(5-10)^2}{10}+\dfrac{(8-10)^2}{10}+\dfrac{(9-10)^2}{10}+\dfrac{(8-10)^2}{10}+\dfrac{(10-10)^2}{10}+\dfrac{(20-10)^2}{10} = 13.410(5−10)2​+10(8−10)2​+10(9−10)2​+10(8−10)2​+10(10−10)2​+10(20−10)2​=13.4
  4. 4Degrees of freedom
    df=k−1−mdf = k - 1 - mdf=k−1−m
    ↓
    df=6−1−0=5df = 6 - 1 - 0 = 5df=6−1−0=5
  5. 5p-value and critical value
    p=P(χ52≥13.4)p = P(\chi^2_{5} \geq 13.4)p=P(χ52​≥13.4)
    ↓
    p=0.01991, χc2=11.07p = 0.01991,\ \chi^2_c = 11.07p=0.01991, χc2​=11.07
  6. 6Decision
    p<α=0.05p < \alpha = 0.05p<α=0.05
    ↓
    reject H0\text{reject } H_0reject H0​
  1. Tools
  2. Statistics
  3. Chi-Square Calculator
  4. Chi-Square Goodness of Fit Calculator

About Chi-Square Goodness of Fit Calculator

This chi-square goodness-of-fit calculator tests whether the observed counts in your categories match an expected distribution, with equal, proportional or custom expected values. It is free, needs no sign-up and runs in your browser, so nothing you enter is uploaded.

The page opens on a classic example: a die rolled 60 times that landed 5, 8, 9, 8, 10 and 20 times on its six faces. With equal expected counts of 10 the chi-square is 13.4 on 5 degrees of freedom, which is significant at the 5% level, and the contributions show that the 20 sixes drive the result.

Choose All equal for a fair-die or uniform test, Proportions for a ratio such as the 9:3:3:1 of Mendel’s peas, or Counts if you already have expected counts that add up to the observed total. If you estimated parameters from the data, enter how many, and each one takes away a degree of freedom.

How to use Chi-Square Goodness of Fit Calculator

  1. 1Choose the test: goodness of fit, independence or critical value.
  2. 2For goodness of fit, type the observed counts and choose how the expected values are given. For independence, type the counts into the table and add or remove rows and columns as needed.
  3. 3Choose a significance level, usually 0.05.
  4. 4Read the chi-square statistic, the degrees of freedom, the p-value, the critical value and, for a table, Cramér’s V.
  5. 5Check the warning about small expected counts, then open the expected counts, contributions and step-by-step working.

Features

  • Goodness of fit with equal, proportional or custom expected values, and an option for estimated parameters.
  • Test of independence with an editable contingency table up to 10 by 10, usable on a phone.
  • Expected counts and each cell’s contribution to chi-square.
  • Cramér’s V effect size with a plain-language label.
  • A warning when any expected count is under 5.
  • Critical value look-up for any degrees of freedom and significance level.
  • A bell curve with the rejection region and statistic, and step-by-step KaTeX working.

Goodness of fit

The statistic sums the standardised squared differences over the k categories.

χ² = Σ (O_i − E_i)² / E_i,   df = k − 1 − m
E_i = N × π_i

Worked examples

  • Die: 5, 8, 9, 8, 10, 20 against equal counts → gives χ² = 13.4, df = 5, p = 0.020

    Wikipedia, chi-squared test, fair-die example.

  • Peas: 315, 108, 101, 32 against 9:3:3:1 → gives χ² = 0.47, df = 3, p = 0.925

  • 18, 22, 20, 40 against 25 each → gives χ² = 12.32, df = 3, p = 0.006

Privacy: how it works

  • The test is calculated by code in your own browser tab. Your counts are not sent to Ulkaa or any other server.
  • There is no account and nothing is stored once you close the tab.

Tips

  • Enter counts, not percentages. Percentages change the sample size and so the statistic.
  • For a 2 by 2 table the test of independence with no continuity correction can be a little too liberal. Compare with Fisher’s exact test when counts are small.
  • Look at the contributions to see which cells drive the result, instead of stopping at the p-value.
  • Rows and columns of a table must each contain at least one non-zero count.

Frequently asked questions

Is it really free?

Yes. There is no price, no trial and no credit card. Ulkaa Tool does the work with your own device, so there is no server bill to pass on to you.

Do I need an account?

No. There is no sign-up and no login. Open the page and use it. An Ulkaa account is not needed for anything on this tool.

Does it run in my browser?

Yes. Your counts are processed by code running in your browser tab, on your own device.

Is my data uploaded?

No. Your counts are never sent to Ulkaa or to anyone else. You can check this yourself by watching the Network tab in your browser developer tools while you use the tool.

What does goodness of fit test?

Whether the observed distribution of one categorical variable differs from a distribution you expected, such as equal frequencies or a genetic ratio.

Why did the p-value come out very high?

A p-value close to 1 means the observed counts are very close to the expected ones, closer than chance alone usually produces. It is not evidence of a problem by itself.

More Chi-Square Calculator pages

  • Chi-Square CalculatorRun a chi-square goodness-of-fit test or a test of independence on a contingency table, with expected counts and Cramér’s V.
  • Chi-Square Test of Independence CalculatorEnter a table of counts and see whether the two variables are related.
  • Chi-Square Critical Value TableLook up the chi-square critical value for any degrees of freedom and significance level.

Ulkaa Apps

  • Ulkaa
  • Calendar
  • Task
  • Note
  • Disk
  • Call
  • Contact
  • Mail
  • Finance
  • Health
  • Office
  • Work
  • Workspace
  • Halum
  • Jaal
  • Islam
  • Game
  • Weather
  • Campus
  • News
  • Developer
  • Help
  • Account
About·Privacy·Terms·© 2026 Ulkaa

What is Ulkaa Tool?

Ulkaa Tool is a free collection of fast, privacy-friendly online tools from Ulkaa Network. Calculate your GPA and CGPA, edit rich text, count words and characters, replace text and more — all in your browser.

Every tool runs entirely in your browser — no sign-up, and your data never leaves your device.

Academic

  • GPA Calculator
  • CGPA Calculator
  • Citation Generator
  • Quiz Maker

Text

  • Rich Text Editor
  • Word Counter
  • Character Counter
  • Text Replacement

Ulkaa

  • Ulkaa
  • Ulkaa News
  • Ulkaa Campus
  • Ulkaa Tool
  • Ulkaa Game
  • Ulkaa Weather
  • Ulkaa Islam

Company

  • About Ulkaa
  • Careers
  • Support
  • Help
  • Privacy Policy
  • Terms of Service
  • Disclaimer
  • Sitemap

© 2015-26, Ulkaa. All rights reserved.
Facebook PageLinkedIn CompanyX (Twitter) ProfileInstagram ProfileGitHub Account