How we shuffle
Every online hand at Larry’s House is dealt from a deck that is locked before the deal, shuffled with randomness from your device as well as ours, and opened up after the hand so anyone can check it. You don’t have to trust us. You can check.
The short version
- We lock the deck first. Before each deal, our server picks a secret random number (the server seed) and shows everyone at the table its fingerprint. A fingerprint can’t be turned back into the seed, but it pins the seed down: if we swapped the seed later, the fingerprint wouldn’t match.
- Your device adds its own randomness. While you’re seated, your phone or computer picks a random number of its own (your player seed) and sends it in. The deck is shuffled from the server seed and every player’s seed together. We locked our seed in before we saw yours, so we can’t choose a deck we like.
- We open the lock after the hand. When the hand ends, the server reveals its seed. Your device rebuilds the deck on its own and checks that the seed matches the fingerprint, that your seed was used, and that your cards and the table cards came from that deck.
The result shows on the fair-deal line at the table: a green ✓ when the hand checks out, and a red ✗ with the reason if anything doesn’t.
Where the randomness comes from
- The server seed is 32 bytes from the operating system’s cryptographic random number generator, the kind used for passwords and encryption keys. Nothing in the game uses a predictable random function for cards.
- Each player seed is 16 bytes from your browser’s cryptographic random number generator.
- The cards are shuffled with Fisher-Yates, the standard shuffle in which every one of the 52! possible orders of the deck is equally likely.
- The server deals, checks every move and moves the chips. Nobody’s device ever receives another player’s cards before the showdown.
Check a hand yourself
The table checks every hand you’re dealt into automatically. To see the whole deck for yourself, open the fair-deal line at the table after a hand, tap the Copy hand details button, and paste them here. The deck is rebuilt in your browser; nothing is sent anywhere.
The exact recipe
For anyone who wants to check a deck with their own code, this is exactly how a deal is built from the seeds in a hand’s details:
- Fingerprint: SHA-256 of the server seed’s 32 bytes (decode the hex first), written as lowercase hex. It must equal the
commitment. - Player seeds: sort them by player id and join them as
id:seed, separated by commas. Call itP. Empty if nobody’s seed arrived in time. - Random stream: block
n(0, 1, 2…) is HMAC-SHA256 keyed by the server seed’s bytes, over the textP|0|n. Read each block as eight big-endian 32-bit numbers. - Unbiased picks: to pick a number below
k, take the next numberwfrom the stream. Ifwis below the largest multiple ofkunder 2³², the pick isw mod k; otherwise skip it and take the next. - Shuffle: start from the deck in order (clubs, diamonds, hearts, spades; ace to king within each suit). For
ifrom 51 down to 1, pickjbelowi + 1and swap cardsiandj. Card 0 is the top of the deck. - Deal: in Double-Suit Badugi, Down the River, Texas Hold’em and Omaha, cards go round one at a time from the top, starting at the seat left of the button, and the table cards come next. Wigg Game, Jelly Game and Clock deal in their own order, as each game’s How it works page describes; the checker above deals every game the way the server does. If a draw empties the deck, the discards are reshuffled the same way with
|1|, then|2|, in place of|0|.
What it doesn’t cover
- Practice tables. They run in your browser against bots, with your browser’s cryptographic random number generator, and have no fair-deal check.
- Folded hands are revealed. Opening the deck after the hand shows every card, including hands that were folded and table cards nobody turned up.
- No outside audit. We haven’t had the deals tested by an independent lab. The check above is how you can test them yourself.
Chips are play money with no cash value. See About for more on how the game works.