How Slot RNG Works: Random Number Generators Explained
The hidden program that decides every spin: what it is, how it turns numbers into symbols, and how regulators check it.
The short answer
A slot's random number generator (RNG) is a program that produces a constant stream of numbers with no predictable pattern. When you press spin, the game reads the numbers it receives at that instant and converts them into reel positions using its math model. The result is decided before the reels move, every spin is independent, and in regulated markets the RNG must be independently tested before a game can be released.
What an RNG is
A random number generator (RNG) is a program that produces numbers with no pattern anyone can predict. In a slot, those numbers are the "dice" behind each spin. Whenever the game needs a result, it takes the numbers the RNG is producing at that moment and uses them to decide where each reel stops.
The spinning reels, the sounds and the celebration animations are presentation. By the time they start, the outcome has already been decided. For the big picture of how all the parts fit together, see our complete guide to how slot machines work.
Pseudo-random vs true random
Most slot RNGs are pseudo-random: a mathematical formula that starts from a value called a seed and produces a very long sequence of numbers that pass statistical tests for randomness. The seed can come from unpredictable inputs, and some systems also draw on physical sources of randomness such as electronic noise.
For gambling, what matters is not the philosophy of randomness but whether the output has the right properties. UK Gambling Commission guidance for online games lists four qualities an RNG should be able to demonstrate (see RTS 7):
Evenly spread
Output is uniformly distributed across its whole range, and game outcomes follow their expected probabilities.
Unpredictable
It should be computationally infeasible to predict the next number without complete knowledge of the algorithm and the seed.
No repeating cycle
The RNG does not reproduce the same output stream, and two instances do not produce the same stream as each other.
Safe seeding
Any seeding or re-seeding must not introduce predictability, and scaling the output must not damage these qualities.
From random number to symbols
An RNG produces numbers, not symbols. The game software turns one into the other in a few steps.
- You press spinThe game requests random numbers from the RNG.
- The RNG supplies numbersIn a simple game, one number per reel, scaled to the range of that reel's "virtual stops".
- Each number selects a virtual reel stopEvery stop holds a symbol, and the symbols are not equally common.
- The game works out the resultIt looks up the symbols, checks the paytable and pays any win or triggers a feature.
- The reels animate to show itThe spinning is only a visual effect. The result is already fixed.
Why the symbols you see aren't equally likely
A reel can have many more virtual stops than visible positions, and the game can place far more low-paying symbols on it than high-paying ones. That is how a top-prize symbol can appear on screen yet occur rarely in practice. It is part of the game's math model, which also sets its RTP.
Under the UK standard, this mapping must follow the game's stated probabilities and pay tables, and the numbers must be used in the order they are received. They cannot be thrown away to steer a result.
Try it: virtual reel demo
This is a simple toy slot with three reels. Each reel has the same 20 virtual stops, shown below, but the symbols are not equally common. Spin it once to see the numbers drawn, then run 1,000 spins to see how results settle around the maths.
One reel's 20 virtual stops
The number under each symbol is the stop number the RNG can pick (0 to 19).
Press a button to draw numbers.
Last 1,000-spin run
- Spins
- -
- Wins (three of a kind)
- -
- Triple sevens
- -
- Longest losing streak
- -
What the maths says
- Chance of a win per spin
- 7% (about 1 in 14)
- Expected wins in 1,000 spins
- about 70
- Chance of triple sevens
- 1 in 8,000
- Expected in 1,000 spins
- about 0.125
A toy game for learning, using your browser's random number source. Real slots have many more stops, symbols and features. Notice how long the losing streaks can get even though wins are fairly common: streaks are a normal part of randomness, not a sign that something is "due".
Rules a regulated RNG must follow
Using the UK as an example, the Gambling Commission's technical standard for online games sets out clear rules for random outcomes.
- "Acceptably random." It must be possible to show, to a high degree of confidence and through statistical analysis using generally accepted tests, that RNG output and game results are random.
- No adaptive behaviour. Games may not automatically or manually change the probability of outcomes during play. These so-called "compensated games" are not permitted. Bonus features with different rules triggered by random events are allowed.
- No fake near misses. A game may not replace one losing outcome with a different losing outcome to create a near miss.
- No changing the odds while a game is live. Rules, payouts and outcome probabilities can't change while the game is available, except as the game's own rules allow, and changes must be shown to players.
These requirements are from RTS 7: Generation of random outcomes. They apply to remote gambling licensed in Great Britain. Other regulated markets set their own rules, which often cover similar ground, so check the regulator for your location.
How RNGs are tested
An RNG can't be judged by watching a few spins. It takes large samples and statistical tests, run by independent laboratories.
In Great Britain, operators making remote gambling software must use a test house from the Commission's approved list, and test houses must have full accreditation to the ISO/IEC 17025 laboratory standard. The Commission's framework also requires test houses to be independent of operators, and new games and RNGs can only be released once testing is complete and the report has been provided to the Commission.
After release, the Commission's guidance describes how operators should monitor a game's live return against its expected range. The size of the normal range depends on the game's volatility. In the Commission's worked example, a game with a standard deviation of 5.6 can sit about 4.9 percentage points either side of its theoretical RTP after 50,000 plays and still be working correctly. This is why a few hundred spins tell you almost nothing, a point we explore in our guide to slot volatility.
What it means for you
- There is no pattern to find. Past spins say nothing about the next one, so no machine is "hot", "cold" or "due".
- Timing doesn't help. The result is decided when you press spin. Stopping the reels early or pressing at a particular moment does not change it.
- Autoplay and manual play have the same odds. They use the same maths. Autoplay just spends your money faster.
- Bet size doesn't change the RNG. A bigger bet scales wins and losses but not the odds of a spin.
- Demos use the same maths in regulated markets. In the UK, operators must take all reasonable steps to make sure play-for-free games accurately represent the likelihood of winning and prize distribution of the real-money game on the same site.
If you want to know whether the whole setup can be trusted, read Are online slots rigged?.
Need support? Read our Responsible Gaming guide for warning signs and safer-play tools. In the United States, the National Problem Gambling Helpline offers free, confidential help 24/7.
RNG myths vs facts
| Myth | Fact |
|---|---|
| "Slots pay out on a schedule or cycle." | Each spin is decided separately by the RNG. Compensated, pattern-based payout adjustment is not allowed in regulated UK games. |
| "The machine remembers if I've been unlucky." | The RNG has no memory of your results. Every spin is independent. |
| "There are better and worse times of day to play." | There is no time-of-day setting. Outcomes are decided by the RNG at the moment you press spin. |
| "A prediction app or system can call the next spin." | A properly designed, regulated RNG should be computationally infeasible to predict. Treat anything promising to predict spins as a scam. |
| "Online RNGs are less random than casino machines." | Casino-floor slots and online slots both rely on RNG software. What differs is how each is regulated and tested. |
Frequently asked questions
What does RNG stand for in slots?
RNG stands for random number generator. It is the program that produces the random numbers a slot uses to decide the result of every spin.
Is a slot machine RNG truly random?
Most slot RNGs are pseudo-random, meaning they use a mathematical formula that produces numbers passing statistical tests for randomness. Regulators require results to be acceptably random, shown through statistical analysis, and unpredictable in practice.
Can slot RNGs be predicted?
In a properly designed, regulated game, no. UK guidance says it should be computationally infeasible to predict the next number without complete knowledge of the algorithm and seed. Apps or systems that promise to predict spins should be treated as scams.
Does the RNG know if I have been winning or losing?
No. In regulated markets, adaptive behaviour is not allowed, meaning games cannot change the probability of outcomes during play based on past results. Every spin is independent.
Who tests slot RNGs?
In Great Britain, independent test houses approved by the Gambling Commission test games and RNGs against the technical standards before release. They must be accredited to the ISO/IEC 17025 laboratory standard. Other regulated markets have their own approved laboratories.
Are demo slots driven by the same maths as real-money slots?
In the UK, operators must take all reasonable steps to make sure play-for-free games accurately represent the likelihood of winning and prize distribution of the real-money game. A short demo is still a small sample, and demos on a game supplier's own website may be built to show off features.
Key takeaways
- An RNG is a program that produces unpredictable numbers, and the game converts them into symbols using its math model.
- The result is decided the moment you press spin. The reels and sounds are presentation.
- Symbols on a virtual reel are not equally likely, which is how rare top prizes are built.
- Every spin is independent, so no machine is hot, cold or due.
- In regulated markets, RNGs are independently tested and games may not adjust odds based on your results.
- Long losing streaks are normal randomness, not proof of anything.
Read next
Sources and further reading
We based this article on regulators' technical standards and guidance. Rules change, so check the originals for the latest detail.
- UK Gambling Commission: RTS 7, Generation of random outcomesThe standard on acceptably random outcomes, adaptive behaviour, near misses and unchanging odds.
- UK Gambling Commission: RTS 6, Result determination for play-for-free gamesRequirements for demo games to represent the real game.
- UK Gambling Commission: Test housesHow approved, accredited test houses are used to check gambling software.
- UK Gambling Commission: Live return to player performance monitoringHow volatility sets the normal range around a game's RTP.
- National Council on Problem Gambling: National HelplineFree, confidential support in the United States.
