The trust problem
If a server tells you "here is a random number," how do you know it wasn't picked on purpose? Provably fair randomness solves this by letting you mathematically prove, after the fact, that the result was not chosen to favour anyone.
The three ingredients
Every provably fair outcome relies on three pieces:
- Server seed — a secret random string the server generates and commits to before you ask for an outcome.
- Server hash — a cryptographic hash (SHA-256) of the server seed, published up front. Once it's out, the server seed cannot be changed without the hash also changing.
- Client seed — a value you choose. Because the server has already committed to its seed, your contribution makes the final result unpredictable to either party.
The verification flow
- The server gives you a
serverHashbefore you ever request a number. - You request an outcome, supplying your
clientSeed. The API combines server seed + client seed + a nonce and hashes the result to derive the random value. - When you're ready, the server reveals the original
serverSeed. You hash it yourself and confirm it matches theserverHashyou were given earlier. - You re-run the same hashing math locally with the revealed seeds. If you get the same outcome, the result was provably fair.
Try it now
Head to the verification page, paste a clientSeed and serverHash from any past response, and confirm the result. The page calls GET /api/verifyServerHash and tells you instantly whether the values match our records.