RNG Test Tool

Run the NIST SP 800-22 battery in your browser

Paste or upload raw RNG output and this tool runs the actual NIST statistical randomness tests — computing real p-values and pass/fail with nothing sent to a server. This is the same analysis that backs a CCF Labs certificate. The code runs entirely on this page; view source to audit it.

Input format

Uploaded text files (hex, 0x-prefixed hex, 0/1 bitstrings or base64) are read exactly like pasted input; any other file is read as raw binary bytes. Certification runs use at least 1,000,000 bits (CCF-STD-001 § 5.2).

What this tool does — and doesn't

This runs 8 core tests from the NIST SP 800-22 battery (Frequency, Block Frequency, Runs, Longest Run of Ones, Discrete Fourier Transform, Serial, Approximate Entropy, and Cumulative Sums). Each computes real p-values using the statistical methods defined in NIST SP 800-22; the Serial test reports both of the p-values NIST defines for it (P1 and P2) and passes only if both are ≥ 0.01. Passing means the output shows no statistically detectable departure from randomness for these tests — it does not show that a generator is unpredictable (CCF-STD-001 § 10). Samples shorter than 1,000,000 (10⁶) bits — the sequence length NIST SP 800-22 uses in its worked examples and recommends for several of its tests, and the certification minimum in CCF-STD-001 § 5.2 — are reported as demonstration runs (§ 5.1), not as evidence that a generator is fair.

A full CCF Labs certification goes further: it fixes the exact game build being tested, runs the battery over a certification-grade sample (≥ 1,000,000 bits) collected under a defined sampling protocol, records the sample's SHA-256 hash, and version-locks the certificate to the build so it only covers the code that was actually tested. The complete procedure — sampling requirements, decision rule, and revocation policy — is published as CCF-STD-001, the RNG Statistical Testing Standard. A passing result here is a necessary signal, not a substitute for that process. Certification does not constitute gambling authorization or regulatory approval.