Benford's law analyzer
Compare the first-digit distribution of a data set against Benford's law.
Benford's law analyzer
Paste a column of numbers — financial figures, transaction amounts, populations, anything with a few hundred entries or more — and this tool counts how often each digit from 1 to 9 appears first, then compares that against Benford's law. In naturally occurring data the leading digit isn't uniform: a 1 shows up first about 30% of the time, a 9 barely 5%. A data set that drifts far from that curve is worth a second look, which is why auditors and fraud examiners use this test as a first screen.
Values can be separated by spaces, commas or new lines — auto-detect handles a mixed paste with no setup. Decimal places sets how many digits the percentage columns show. The deviation formula switches between the population and sample convention for the spread of the nine digit differences, the same choice behind any standard deviation. Intermediate steps adds the raw extracted digits, a count row and a row of differences, showing how the numbers were built. Ignore invalid values skips text, blanks and zeros instead of stopping on the first one; zero has no leading digit under Benford's law.
The result reports how many values were analyzed and skipped, the mean absolute deviation between observed and expected percentages — read out as close, acceptable, marginal or nonconformity using standard forensic-accounting thresholds — and the standard deviation of the differences. None of this proves fraud alone: small samples and digit-heavy data, like invoice numbers, also drift from the curve. A large deviation is a reason to look closer, not a verdict.
Everything runs locally in your browser: pasted numbers are never uploaded. Copy the report, download it as a .txt file, clear the panel, or send the output back into the input to rerun with different options.