The Glitchhouse · Pokemon Red and Blue

The Ditto glitch

A wild Ditto copies one number when it Transforms, and that number decides which Pokemon walks out of the next patch of grass. Dial it to 21 and you catch a Mew. Dial it higher and you catch things that were never meant to exist.

Decoded from a Pokemon Red ROM · part of The Glitchhouse

The Mew glitch has a famous cousin that is quieter and far more precise. Instead of leaving a trainer's number in memory, you battle a wild Ditto, let it use Transform, and it copies your Pokemon's Special stat into the exact spot the game will later read as a wild species. The Special stat becomes the Pokemon. Twenty-one is Mew. Everything above one hundred and ninety is a glitch. It is a dial with the whole Pokedex, and then some, printed on it.

The Special stat is a dial

Here is the heart of it. When the Mew glitch fires, the game reaches for a wild species and finds the leftover Special stat instead, and it reads that number as a Pokemon's internal index. So the Special stat you left in memory is the Pokemon. Slide it and watch the whole Pokedex, and everything past it, scroll by.

The number is an internal index, which is not the same as a Pokedex number: index 21 is Mew, 131 is Mewtwo. Values that land on a real slot give a real, catchable Pokemon; values that land on the gaps between them, and everything from about 190 up, give MissingNo and the other glitch Pokemon. And because it is a single byte, a Special of 256 or more simply wraps back to zero and counts up again.

Past the real Pokemon: the gaps

Dial the Special above the last real Pokemon and you stop catching monsters and start catching memory. These are the gaps in the index, the famous MissingNo forms, and the Ditto glitch is the cleanest way to reach an exact one. Every sprite here is a real one caught in the act, then hand-cleaned by Garden. Pick a gap.

Each of these lands on a specific Special stat, so a Ditto tuned to that exact number summons that exact glitch. They are decoded byte for byte on their own Glitchhouse pages; here they are just the far end of the same dial.

Where the number comes from

So how do you land the dial on exactly 21? The Special stat is not magic; it is an ordinary battle stat, worked out from a Pokemon's base Special, its level, and a hidden value called a DV. To hit a target, you pick a Pokemon and a level whose Special comes out to the number you want. Slide these and watch the Special, and the Pokemon it would summon, change together.

SPECIAL STAT = 21
Gen 1 stat formula with no stat experience: Special = floor((base + DV) × 2 × level ÷ 100) + 5, verified in home/move_mon.asm. The Mew glitch reads that final Special stat as a species index, so a Pokemon whose Special works out to 21 hands you a Mew. The DV is the hidden 0 to 15 value every Pokemon rolls when it appears.

Does it still work

The Ditto glitch is not a bug in one cartridge; it is how the wild encounter reads memory, so it lives wherever the game does. What changes from platform to platform is only your safety net, and here the trick is unusually kind: dialed to a real Pokemon like Mew it is completely safe, and only becomes risky if you steer it into the glitch Pokemon. Pick where you are playing.

Wild Ditto and the Special-stat read are in every version, so the glitch works the same everywhere. Catching a Mew this way gives you a genuine, tradeable Mew and touches nothing else. The only danger is on the far end of the dial, the MissingNo values, which can scramble your items and Hall of Fame, and on a cartridge that has no undo.

The other thing Ditto sets

The Special stat is only half of what a provoked Ditto leaves behind. The exact same setup, the number of times you make Ditto raise or lower a stat before you leave, also decides which trainer's roster the game loads if you glitch into a trainer battle instead of a wild one. TheZzazzGlitch mapped these: two Growls loads roster 5, one Swords Dance loads roster 9. And if the count lands on a roster that has no Pokemon in it, you do not get a battle. You get ZZAZZ.

The same Ditto that dials your wild species can dial a trainer's roster instead, a fact TheZzazzGlitch worked out by mapping all of them. Most rosters hold a real team; the empty ones are the trigger for ZZAZZ, the glitch trainer that maxes your money and eats your save. One wild Ditto, two very different doors.

Catch Mew

Every dial and stat on this page points at one number. Set the Special to 21, let the game read it as the next wild species, and you do not get a glitch or a MissingNo. You get Mew, a real, catchable Mew, the Pokemon that was never meant to be in the game, walking out of ordinary grass. Run the encounter.

A wild Mew
Special is dialed to 21. Press the button.
Special 21 is Mew's internal index, so the encounter summons a genuine, level-appropriate Mew you can catch and keep, no different from a legitimately caught one. The full step-by-step, including the exact Ditto and Trainer-Fly setups, lives on the Mew glitch page. This is just the payoff.

What Transform copies

Ditto's whole gimmick is Transform: it becomes whatever it is looking at, copying every one of that Pokemon's battle stats onto itself. Ditto starts life as five flat 48s. Send out one of your Pokemon, let the wild Ditto Transform, and its stats snap to match. Only one of those copied numbers will matter in a moment, the Special stat, so keep your eye on it.

YOUR POKEMON
TRANSFORM →
DITTO
Ditto is sitting on its own base stats, a famous flat 48 across the board. Press the button and let it copy yours.
Transform copies all five stats onto Ditto (whose own are a flat 48 each, straight from the ROM). The Special stat is the only one the Mew glitch reads later, so it is the number to watch. The values here are an example: the real Special depends on the Pokemon's level and DVs, which is exactly the knob you tune.

From the ROM

Two facts from the game's own source hold this whole page up. The first is the stat formula, the ordinary arithmetic that turns a base stat and a level into the Special number. The second is the internal index list, where Mew sits at position 21, so a Special of exactly 21 points the wild-encounter read straight at it.

; home/move_mon.asm  - CalcStat, with no stat experience
Special = ((base + DV) * 2) * level / 100 + 5   ; every stat but HP

; constants/pokemon_constants.asm  - the internal index list
    const MEW   ; internal index 21 ($15)  <- not its Pokedex number, 151

; the glitch wild encounter reads the leftover Special stat as an index
    ; Special 21 -> index 21 -> MEW. Above 190 -> the gaps -> MissingNo.

That is the entire trick: a normal stat, copied by a Transform, read in a place the game meant for a species number. Line those two facts up and a wild Ditto becomes a dial with the whole Pokedex on it.

A wild Ditto does not know it is a key. It just copies a number, and the game, reaching for a Pokemon, reads that number and believes it.

Go deeper: the Mew glitch | ZZAZZ | browse the Glitchhouse.