Dice Fairness and Roll Frequency Calculator

Enter observed roll counts in face order. This dice fairness calculator compares them with equal expected frequencies and returns a chi-square statistic and approximate p-value.

Try an example

Set up your calculation

Choose this before testing; it is not the probability that the die is fair.

Enter 2–100 nonnegative counts in face order, separated by commas. Each count at most 100000.

Shared links store inputs in the URL fragment. Results are recalculated; no calculator inputs are sent to the server.

Statistical estimate

Statistical estimate

0.992123

Approximate chi-square p-value

χ² 0.500000 · 5 degrees of freedom · 120 rolls

Observed and fair expected face counts
FaceObservedExpectedFrequencyχ² contribution
11820.00015.00%0.200000
22220.00018.33%0.200000
32020.00016.67%0.000000
41920.00015.83%0.050000
52120.00017.50%0.050000
62020.00016.67%0.000000

Observed frequency and expected counts

Roll a die independently under consistent conditions and record the count of each face. With N rolls of an s-sided fair die, each expected count is N/s. Relative frequency is the observed count divided by N. For 120 D6 rolls, each face has expected count 20; a face observed 24 times has relative frequency 24/120 = 20%.

Random variation produces unequal counts even for a fair die. Inspecting just a few rolls cannot establish whether a die is balanced. The weighted dice probability calculator assumes supplied face weights rather than testing fairness.

Calculate a chi-square fairness statistic

For observed counts O and expected counts E, add (O − E)2/E across all faces. Counts 18, 22, 20, 19, 21, 20 out of 120 rolls give (4 + 4 + 0 + 1 + 1 + 0)/20 = 0.5. For a fully specified fair D6 model, compare the statistic with a chi-square distribution with five degrees of freedom.

In a spreadsheet, calculate the fair expected counts and use CHISQ.TEST(observed_range, expected_range) to obtain a p-value. Use sufficiently large expected counts for the approximation, commonly at least five per face, and independent observations. A small p-value is evidence against this fair model; a large p-value does not prove fairness.

Balance, bias and recording limits

A roll-frequency test concerns the complete rolling process, including the surface and method. It does not identify a physical manufacturing defect or measure centre of mass. Do not stop recording when an interesting pattern appears or select only favourable trials. The calculator above accepts observed face counts and computes the statistic and approximate p-value. The NIST goodness-of-fit reference explains the statistic and expected-count condition; Microsoft documents CHISQ.TEST.

Statistical evidence and physical balance

The chi-square test compares observed face counts with an equal-probability model. Its p-value is an approximation, not the probability that the die is fair. Small expected counts weaken the approximation; this test cannot measure a die’s centre of mass.

Read the calculation methodology for exact counting, display rounding and reference checks. To report an unexpected result, send the inputs and the rule you expected through the contact page.