Randomness Explained: PRNGs vs True Random
What ‘random’ really means on a computer — and what powers Mohoh’s tools.
“Random” is one of those words we all use confidently and few of us could define precisely. When you ask Mohoh to flip a coin or pick a name, what does it actually mean for the result to be random — and is a computer even capable of it? This explainer unpacks randomness, the difference between pseudo-random and true random, and what powers Mohoh’s tools.
What does “random” actually mean?
In everyday use, random means “unpredictable and without pattern.” In mathematics it is sharper: a random process produces outcomes where each possibility has a defined probability, and knowing past outcomes tells you nothing about the next. A fair coin is the textbook example — 50% heads, 50% tails, and every flip independent of the last.
Pseudo-random numbers: the workhorses
As we cover in detail in how random number generators work, computers are deterministic, so they fake randomness with a pseudo-random number generator (PRNG). A PRNG starts from a seed and applies a mathematical recipe to produce a sequence that passes statistical tests for randomness, even though it is entirely determined by that seed. For games, simulations and everyday picks, a good PRNG is more than enough.
Cryptographically secure randomness
Some uses — passwords, encryption keys, secure tokens — demand more. A cryptographically secure PRNG (CSPRNG) is engineered so that even an attacker who sees a long run of outputs cannot predict the next one or reconstruct the seed. Browsers provide this via the Web Crypto API’s crypto.getRandomValues(), which draws on entropy collected by your operating system.
Mohoh’s tools — the coin flip, dice, number generator, password generator and the rest — use crypto.getRandomValues() whenever your browser supports it. We also apply “rejection sampling” to avoid the subtle bias that the naive random() % range trick introduces, so every outcome in a range is exactly equally likely.
True randomness: from the physical world
True random number generators do not compute — they measure. They harvest entropy from genuinely unpredictable physical phenomena: the timing of radioactive decay, electronic thermal noise, atmospheric radio static, even the chaotic patterns of lava lamps (famously used by one major web company). Because the underlying physics is fundamentally unpredictable, the results are as random as nature allows.
Pseudo-random vs true random: which do you need?
For the overwhelming majority of purposes — picking a winner, breaking a tie, generating a strong password, running a friendly raffle — a quality CSPRNG is statistically indistinguishable from true randomness, so it is the practical choice. True hardware randomness is reserved for the highest-stakes cryptographic and scientific applications, and for legally regulated systems like national lotteries that must be independently audited.
The myths worth busting
- “That number is overdue.” No outcome is ever “due”. Independent draws have no memory (the gambler’s fallacy).
- “Random means evenly spread.” Genuine randomness is clumpy. Real random sequences contain streaks and clusters; perfectly even spacing would actually be suspicious.
- “Humans can pick randomly.” We are terrible at it — we avoid repeats and patterns that real randomness happily includes, which is exactly why we built tools to do it for us.
The takeaway
Randomness is subtler than it looks, but the practical lesson is simple: a well-built generator gives you fair, unpredictable results you can trust, and you should ignore the instinct to read patterns into them. That is the standard Mohoh holds itself to — explore the tools and put it to the test.
Frequently asked questions
What’s the difference between pseudo-random and true random?
Pseudo-random numbers are computed from a seed by a formula — deterministic but statistically random-looking. True random numbers are measured from unpredictable physical processes like thermal or atmospheric noise. For everyday use, a good pseudo-random generator is effectively as good as true random.
Does random mean evenly spread out?
No — genuine randomness is clumpy and contains streaks and clusters. Perfectly even spacing would actually suggest the results aren’t truly random. Our brains expect randomness to look tidier than it really is.
Can humans generate random numbers in their head?
Not well. People unconsciously avoid repeats and obvious patterns that real randomness includes, making human-chosen ‘random’ numbers quite predictable. That’s exactly why random generators exist.