Skip to content
Omnikalc

Benford's law test: do your numbers follow the first-digit law?

Count how many numbers start with each digit from 1 to 9 and compare with Benford's law: chi-square test, p-value and the mean absolute deviation used by auditors.

Updated on
Your inputs

Value out of range

Value out of range

Value out of range

Value out of range

Value out of range

Value out of range

Value out of range

Value out of range

Value out of range

Results

Mean absolute deviation (MAD)

0.0058

Close conformity with Benford's law (Nigrini)
Chi-square p-value (8 degrees of freedom)
0.9187
Compatible with Benford's law
Chi-square statistic
3.24
Numbers counted
1,000
Observed share starting with 1
28.0%
Expected share starting with 1
30.1%
Observed share starting with 9
4.8%
Expected share starting with 9
4.6%

What Benford’s law says

In many real-world data sets, such as invoices, populations, river lengths, stock prices and tax returns, the first digit is far more often 1 than 9. Benford’s law gives the expected share of each leading digit d:

P(d) = log₁₀(1 + 1/d)

Digit Expected share
1 30.1%
2 17.6%
3 12.5%
4 9.7%
5 7.9%
6 6.7%
7 5.8%
8 5.1%
9 4.6%

The pattern appears in data that span several orders of magnitude and arise from multiplicative processes.

Why auditors use it

People who invent numbers tend to spread first digits evenly, or to cluster just below approval thresholds. A data set that departs from Benford’s law can point to errors, duplicates or fraud. Forensic accountants, tax authorities and election analysts use it as a screening tool, a reason to look closer, never as proof.

How to read the results

  • MAD (mean absolute deviation) between observed and expected shares, with Mark Nigrini’s thresholds for first digits: up to 0.006 close conformity, 0.006 to 0.012 acceptable, 0.012 to 0.015 marginal, and above 0.015 nonconformity.
  • Chi-square test with 8 degrees of freedom. With large data sets it flags tiny, harmless deviations, which is why auditors prefer the MAD.

Example

1,000 invoice amounts with first digits counted as 280, 190, 130, 95, 80, 70, 55, 52 and 48:

  • 28.0% start with 1, against 30.1% expected; 4.8% start with 9, against 4.6%;
  • MAD ≈ 0.0058: close conformity;
  • χ² ≈ 3.24, p ≈ 0.92: no significant departure.

When Benford’s law does not apply

  • Numbers with a fixed range or a minimum and maximum, such as human heights, ages or percentages.
  • Assigned numbers: phone numbers, ZIP codes, invoice or account numbers.
  • Prices set by policy, such as $9.99 tags, or amounts capped by rules.
  • Small samples: below about 500 numbers, the test has little power.

Going further

Auditors also test the first two digits (90 categories), the second digit, and number duplication, which give finer signals. In practice, a Benford anomaly prompts drilling into the specific digits that are over-represented, for example many invoices starting with 4 just below a $5,000 approval limit.

Frequently asked questions

What is Benford's law?

In many natural datasets, the leading digit is 1 about 30% of the time and 9 only about 4.6% of the time.

What does a high MAD mean?

A mean absolute deviation above about 0.015 for first digits suggests the data does not follow Benford's law.

Does a Benford failure prove fraud?

No. It flags data for review. Many legitimate datasets, such as prices or assigned numbers, never follow the law.

Which data follows Benford's law?

Data spanning several orders of magnitude, such as invoice amounts, populations or river lengths.

Was this calculator helpful?

Thanks for your feedback!

Results are estimates provided for information purposes. They do not replace professional advice.