← Back to ColorDice

How ColorDice fairness works

ColorDice generates color dice results with Web Crypto, stores each roll under a public Game ID, and signs the stored record with server-side HMAC-SHA-256.

Quick answer: the proof page lets viewers compare the recorded colors, dice count, timestamp, and signature status with the livestream result. It proves that the stored server record still matches the server signature; it is not a trustless system where users can recompute the private signature themselves.

How to verify

  1. Find the Game ID shown on the livestream.
  2. Open the verification link on your own device.
  3. Compare the colors, dice count, and roll time.

How colors are generated

Each roll uses random bytes from crypto.getRandomValues(). Since 256 is not evenly divisible by 6, ColorDice rejects bytes 252, 253, 254, and 255. It maps only values 0-251 to the six colors with % 6, so each color has the same theoretical probability: 1/6.

ItemValue
Random sourceWeb Crypto crypto.getRandomValues()
Default colorsRed, orange, yellow, green, blue, purple
Roll size1 to 100 dice
Verification statusStored record compared with server signature

What ColorDice stores

ColorDice stores the Game ID, dice count, color sequence, roll time, and server signature. Public recent-roll lists do not show IP addresses, device data, or user identity.

Useful links

Open ColorDice · Tiếng Việt · Deutsch · Français · 中文