How Tetris Randomizers Work (Bag, 7-Bag, Memoryless)

Yellow Scrabble tiles spelling 'people' on a blue background, vibrant and playful.

Why does modern Tetris feel fair when NES Tetris felt like a punishment? The difference isn’t your imagination — it’s the randomizer. How Tetris randomizers work has changed dramatically since 1984, and modern Tetris guidelines define a specific algorithm (7-bag) that guarantees you’ll never go more than 12 pieces without seeing any given tetromino. Older games had no such guarantee, and the drought between I-pieces could feel infinite.

Key takeaways

  • The randomizer is the algorithm that decides which tetromino comes next.
  • Early console Tetris (NES, Game Boy) used near-memoryless or weakly history-aware RNG, so long droughts were possible.
  • Modern Tetris guideline games use the 7-bag randomizer: shuffle one of each piece, deal, repeat.
  • Tetris The Grand Master (Arika) uses the “history” randomizer: pull from random, reroll if a recent duplicate.
  • The randomizer determines whether the game feels like skill or like luck.

What a randomizer is

A Tetris randomizer is the function that decides which tetromino piece the player gets next. There are seven tetrominoes (I, O, T, S, Z, L, J), and the randomizer’s job is to return one each time the game asks. Different randomizers have different statistical properties, and those properties shape the game’s feel more than any other single mechanical choice.

The two questions a randomizer answers are how often each piece appears (the distribution) and how the pieces are sequenced (the order). A perfectly uniform memoryless RNG gives each piece probability 1/7 every time, with no memory of what came before. A bag-based randomizer constrains the sequence so droughts can’t happen.

Memoryless RNG (NES Tetris, Game Boy)

The 1989 NES Tetris and Game Boy Tetris used near-memoryless RNG. On each piece request the game picks a random tetromino with roughly uniform probability, plus a small duplicate check (the NES version, for example, rerolls once if the same piece would come twice in a row; the Game Boy version uses its own short history check).

The result is that piece distributions are uniform in the long run but extremely lumpy in the short run. You can go 20 or more pieces without seeing an I-piece. Or you can get three I-pieces in five draws. The variance is real, and it’s why competitive NES Tetris is partly a luck contest at the highest levels — the player who got the I-piece on level 29 has a structural advantage.

This isn’t a bug. It’s exactly what a memoryless RNG produces. The expected wait between I-pieces is 7 draws, but the variance is high, and the distribution has a long tail.

The 7-bag randomizer (modern standard)

Modern Tetris — Tetris Effect, Puyo Puyo Tetris, Tetris 99 and most games following the Tetris Guideline — uses the 7-bag randomizer, which the Guideline calls the Random Generator. The algorithm is simple: put one of each tetromino into a bag, shuffle the bag, deal them out in order, then refill and shuffle again.

The result is a strong guarantee: you will never wait more than 12 pieces for any specific tetromino. The maximum drought between two I-pieces is 12 pieces (one I at the start of one bag, the other I at the end of the next). On average, an I-piece arrives every 7 draws, same as memoryless. The mean is the same; the variance is dramatically lower.

This makes modern Tetris feel skill-based. You can rely on getting an I-piece for line clears within a predictable window. Strategies that depend on long-term piece flow (like Tetris-stack setups for back-to-back clears) become viable.

The history randomizer (TGM)

Tetris The Grand Master series (Arika, starting 1998) uses the “history” randomizer. The algorithm: pick a random piece. If it matches any of the last 4 pieces drawn, reroll, up to a fixed number of attempts (4 in the first TGM, 6 in TGM2). If still a duplicate after the reroll limit, accept it anyway.

This produces a distribution that’s not quite uniform — pieces are still equally likely in the long run, but the short-term sequence has fewer immediate repeats than memoryless. Droughts can still happen but are noticeably less frequent than NES Tetris. The TGM history randomizer was a major design innovation for its time and held the line until 7-bag became standard.

Tetris The Grand Master 3: Terror-Instinct reworked the idea again, combining the history check with a weighted piece pool that makes long-absent pieces more likely. Players have reverse-engineered it in detail, and the specifics are documented by the TGM community.

NES rerolls and “drought RNG”

NES Tetris is famous for its “drought” mechanic — long stretches without an I-piece — that have been measured by competitive players. The game’s RNG isn’t memoryless in the strict sense; it has a one-piece lookback that rerolls duplicates once. But that’s the only constraint, so longer-distance droughts are statistically common.

Competitive players track droughts closely. As a rough guide, if each draw has about a 1-in-7 chance of being an I-piece, around 1 gap in 100 will run past 30 pieces. That matters because at level 19 and above, an I-piece drought can mean the death of a run. NES Tetris’s high-level meta is partly about managing those droughts — choosing piece placements that survive long droughts and capitalize on the rare double-I cluster.

How the bag shuffle works

The 7-bag implementation typically uses Fisher-Yates shuffle, the standard algorithm for unbiased array shuffling. Each piece in the bag has equal probability of being at any position. The shuffle runs once per bag (every 7 pieces).

Implementations sometimes add extras for the opening. The TGM games never deal an S, Z or O as the first piece, and some other games avoid an S or Z opener, because those pieces leave an overhang on an empty board. It’s a player-friendly bias layered on top of the core algorithm.

Hold and previews

Modern Tetris pairs the randomizer with a preview queue (often 5 or 6 pieces ahead) and a Hold slot (swap out the current piece for one stashed). These features amplify the value of the deterministic-ish randomizer because you can plan around the known future. A five-piece preview plus a hold gives you 6 known piece slots to work with at any time — enormous strategic depth compared to NES Tetris’s single next-piece window.

The preview queue is fundamentally a UX exposure of the randomizer. The game’s underlying piece sequence is generated up front (or in chunks); the preview just shows it to you in advance.

Less common randomizers

Some Tetris variants and clones use other algorithms:

  • 14-bag or larger bag: two (or more) copies of each piece per bag. Droughts get longer than 7-bag but stay capped.
  • 28-piece bag: the Tetris on this site fills its bag with four of each tetromino and draws randomly until it’s empty, so long droughts can happen but every piece is guaranteed to come round.
  • Weighted RNG: some puzzle-style Tetris-like games bias certain pieces for difficulty curves.
  • Adversarial randomizers: joke and research variants such as Bastet (“bastard Tetris”) pick the worst piece for the current board state.

None of these are mainstream. The 7-bag is the standard for any modern Tetris game targeting competitive play or guideline conformance.

Why this matters for the game’s feel

The randomizer is the difference between Tetris feeling like a skill game and Tetris feeling like a slot machine. NES Tetris mixes skill with real luck, especially at high speeds. Modern guideline Tetris is much closer to a pure skill game, where the randomizer is essentially a constraint, not a variable.

This is part of why the modern Tetris scene supports such high skill levels — top players place well over 60 pieces per minute and plan many pieces ahead, which only works when piece flow is predictable.

For more on how Tetris has changed across releases, see our Tetris versions compared guide, or read how the hold piece changes strategy.

Source for the algorithms

The 7-bag rule comes from the Tetris Guideline, The Tetris Company’s internal design standard for licensed games. The Tetris Wikipedia article covers the broader history of the series, and the TGM and NES details above come from years of community reverse-engineering.

Frequently asked questions

What is the 7-bag randomizer in Tetris?

The 7-bag randomizer puts one of each tetromino into a bag, shuffles them, deals them out in order, then repeats with a fresh bag. It guarantees you’ll see all seven pieces in every set of 7 draws (counted from the start of a bag) and never go more than 12 pieces without any specific piece.

Did NES Tetris use the 7-bag randomizer?

No. NES Tetris used a near-memoryless RNG with a one-piece lookback (rerolling immediate duplicates once). Long droughts between specific pieces — especially the I-piece — are a documented feature of NES Tetris and matter heavily in competitive play.

What randomizer does Tetris The Grand Master use?

TGM uses the “history” randomizer: pick a random piece, reroll if it matches any of the last 4 pieces drawn, up to a reroll limit. The reroll count varies across TGM titles, and TGM3 adds a weighted pool that favors pieces that haven’t appeared recently.

Why does modern Tetris feel fairer than older versions?

The randomizer changed. 7-bag in modern guideline games eliminates the long droughts that plagued NES Tetris. Every piece arrives on a predictable cadence, which means your strategy depends on skill rather than waiting for the I-piece to finally show up.

What’s the longest possible drought in 7-bag?

12 pieces. The worst case is a piece at the start of one bag followed by the same piece at the end of the next bag — slot 1 and slot 14, which means 12 pieces between them. No drought longer than that is possible in pure 7-bag.

The takeaway

The randomizer is the hidden engine of Tetris’s feel. Memoryless RNG gives you variance and drama; 7-bag gives you predictable flow; TGM’s history rules sit in between. Modern competitive Tetris is built on 7-bag, and that single algorithmic choice is responsible for the skill ceiling we see today. For a different kind of one-button challenge with no piece queues, the Chrome Dino game sits at the top of this site.

🔌 Connect any AI assistant to dinogame.gg — we run an MCP server: https://dinogame.gg/mcp