A Truly Random Number Generator Is Achieved Using Quantum Mechanics, Said Researchers

A number generator is often used to generate a random number. But know this: no number is truly random.

This is because traditionally, computers generate numbers using what's called a pseudo-random number generator (PRNG). This approach uses a mathematical formula or algorithm to produce a sequence of numbers. It starts with an initial value called a seed. From there, it calculates a seemingly random sequence.

The weakness is that, the approach is entirely based on a fixed algorithm, meaning that it’s entirely deterministic.

Whenever the same is used, the succeeding numbers can be calculated because overtime, patterns or cycles will emerge (though they’re often hard to detect). But that predictability is what makes it pseudo-random, not truly random.

Being a non-entropy-based, PRNG is predictable.

In order to generate a "truly" random number, a generator should rely on chaotic or unpredictable physical events, like physical phenomena, atmospheric noise, radioactive decay, or even the timing of keystrokes, to produce numbers that are not mathematically predictable.

Or, it can use a quantum machanics.

Random number generator
A device that uses quantum mechanics to generate truly random numbers in the NIST Boulder laboratories.

Random number generation plays a vital role in a range of domains, from jury selection to secure cryptographic systems.

While quantum mechanics has long been seen as a promising source of true randomness, leveraging its unpredictable nature, it’s the phenomenon of quantum entanglement that brings both promise and complexity.

Entangled particles remain linked regardless of the distance between them, making them ideal for validating random outcomes. However, past implementations were vulnerable to manipulation — particularly through the timing of measurements.

But this time, researchers in the U.S. managed to develop a cutting-edge technique for generating truly random numbers — and, critically, making them tamper-resistant in a way never achieved before.

The novel approach, detailed in a paper published on Nature by postdoctoral researcher Gautam Kavuri and colleagues at the University of Colorado Boulder may offer a major breakthrough.

The project, dubbed the Colorado University Randomness Beacon (CURBy), utilizes entangled photon pairs observed simultaneously at two different sites, spaced 110 meters apart.

Their design incorporates a publicly accessible hash chain, which records the timing of entangled photon measurements. This structure significantly raises the bar for potential attackers seeking to falsify data.

Each measurement is cryptographically logged to the blockchain-like hash chain, enabling full public transparency. Over a 40-day span, the team generated random outputs 7,454 times — 7,434 of which passed the randomness test, achieving a reported 99.7% reliability.

Random number generator
(left-right) Jasper Palfree (University of Colorado Boulder), Gautam Kavuri (NIST) and Krister Shalm (NIST).

Randomness is remarkably useful.

People have been drawing straws and rolling dice to flipping coins to achieve randomness, in order to make things fair and unbiased.

In modern contexts, randomness plays an even more critical role—auditors use it to ensure impartial sampling, and in cybersecurity, randomness becomes a shield. When passwords or encryption keys are composed of unpredictable numbers, they become far more difficult to crack. That’s why modern cryptographic systems depend heavily on random number generators to create secure digital fortresses.

Classical computers can only generate pseudorandom numbers—sequences that appear random but are ultimately governed by deterministic algorithms. Anyone with deep enough insight into how these algorithms function—or access to the initial conditions, such as the seed—could predict the outcome or even manipulate it.

"True randomness is something that nothing in the universe can predict in advance," said Krister Shalm, a physicist at the National Institute of Standards and Technology (NIST), co-author of the paper.

Quantum mechanics however, is inherently random.

Genuine unpredictability can be found only in the quantum realm, because the tiniest particles exist in indefinite states until measured.

[block:block=87]

The scientists harness this natural randomness through loophole-free Bell tests, experiments that use entangled particles and measurement settings chosen at random and in real time. These tests offer a way to certify that the results are truly random, even if individual devices themselves can’t be fully trusted — a strategy known as device-independent randomness.

Using this approach, Shalm and his team have transformed this source of true quantum randomness into a traceable and certifiable random-number service.

Not only that the numbers generated using this high security of quantum random-number generation with a classical protocol ensures an output is truly random, but it also has the randomness can be verified.

And also because the quantum entanglement means that any attempt to manipulate the outcome would require simultaneous, undetectable compromises across both the quantum measurement logs and all associated hash chains.

This, is a near-impossible feat.

The entire process is "a really paranoid way to make sure things are really random," co-author Gautam A. Kavuri said. "You would need to communicate faster than the speed of light to be able to spoof this."

This is because the process repeats 15 million times in about a minute, creating a massive stream of raw random bits.

After quality control tests, computers at the university combine the stream with the next random number sample from a third institution, another public beacon. Everything is processed through an algorithm that filters out any patterns. The result is 512 binary digits of certified pure randomness.

This is equivalent to 10154 possible strings of bits, which each translate to a different number. The number is so massive that it dwarfs the number of atoms in the observable universe.

Random number generator
Physicist Gautam Kavuri (center) and his colleagues working on the random number generator protocol at the National Institute of Standards and Technology.

"God does not play dice with the universe," once said Albert Einsten. But now, scientists prove that Einstein was wrong.

"If God does play dice with the universe, then you can turn that into the best random number generator that the universe allows," Shalm said. "We really wanted to take that experiment out of the lab and turn it into a useful public service."

He added that systems built on this foundation could reinforce trust in digital processes at a time when public skepticism is rising.