On recent occasions, several Gotham City citizens have fallen victim to a mysterious computer hacker. What's more, a strange riddle is left at every scene. First, a late night jogger tries to make a withdrawal from an ATM, only to have his account wiped clean. With it came the message "Where does a 500 pound gorilla sleep?". Later, the Stock Market is attacked along with the question "What's worse than a millipede with flat feet?" Finally, the Department of Motor Vehicles is attacked, with the riddle, "How do you fit 5 elephants into a compact car?"
Under pressure from the press, Batman and Commissioner Gordon deduce that The Riddler is behind this, and also discover that Edward Nygma (Riddler's true name) is erasing all of his personal records from existence (or as Riddler puts it, "deleting Nygma"). Just then, Gordon gets a message that a crate with a question marks painted on it has been delivered to the Department and it's ticking.
Meanwhile, the Police Records Room is evacuated but the guards turn out to be the Riddler's men and they steal the hard copies stored there. Batman, Gordon and Robin go to investigate the crate and discover that it's a variation on the Chinese Box Puzzle. Robin claims he can open it as he had once solved the "Baxter’s box puzzle in 37 seconds" and off side mentions how he had a sledgehammer. All the same, Robin manages to find the secret way to open the crate and finds that it's a giant computer. Robin is assigned to investigate it while Batman returns to the Batcave.
Later, in the Bat-cave Batman and Alfred try to decipher the clues, and eventually realize that the clues aren't in the answers, but the questions themselves. More specifically, the numbers in the questions (500, 1000, 5). Batman then converts the numbers to Roman Numerals getting the letters D, M & V, indicating that the Department of Motor Vehicles is once again his target. Batman unsuccessfully attempts to stop Riddler's men from stealing Nygma's information. And when Batman tries to stop them Riddler attacks him with a robot controlled van filled with nitro glycerin. Batman manages to evade the van but the subsequent fire caused by the explosion takes up his time as he tries to put it out.
While this is happening, Robin is at police headquarters, examining the computer left there. He explores the mainframe and finds it's a virtual reality simulator. He invites Gordon to try it and shows him the program that Gordon claims, "even feels real." Robin leaves Gordon to get a snack and immediately discovers that the door has been locked. Riddler then takes control of the program and "kidnaps" Gordon by trapping his mind in the virtual reality program. Meanwhile, Batman puts out the fire and Riddler contacts him on a payphone; leaving him a riddle, "Ask me no questions, I'll tell you no tales." The phone then drops out four quarters and a penny. Deducing that a penny is made of copper and copper is another word for police and that the "no tales" meant "no tails on the quarters" thereby leaving him with only head quarters Batman realizes Riddler is directing him to Police Headquarters. And the fact that four quarters and a penny makes one hundred one cents means he's to go to room 101.
When he gets there, he finds Riddler hooked up a cordless modem and Gordon is inside the virtual world, strapped onto a rapidly spinning "swing carousel" type ride. Everything that happens in the program will seem so real to Gordon that his body will react as if it truly happened so his heart is beating at a dangerous rate and simply shutting off the program would be like "hitting a brick wall at 400 miles an hour." After giving Robin a microphone so that they can still talk to one another, Batman goes "inside" the machine to save Gordon.
Batman finds himself in an endless hall of doors and Riddler tells him to find the door that "leads to a plane where kings and queens contend." Unable to figure out the riddle, Batman opens a door at random and finds three question marks that start firing exploding dots at him. Evading them, Batman opens a door marked "crazy intent" which also means "loco motive." The door releases a train that smashes the question marks and Batman moves on. Robin finally realizes that the riddle refers to a chessboard. Finding a door marked 4096 which is sixty-four squared (a pun on there being sixty-four squares on a chessboard) he enters.
Riddler tells Batman that only Batman can put the king in check and that he has to "move according to the rules or it's the end of the day." The pieces attack Batman and he runs from them finding that the tiles break under his feet. Realizing that Batman is the Dark Knight, Robin realizes Batman must move like a knight and put the white king in check. Batman does so creating nightfall and is knighted. Suddenly Batman finds himself riding on a Pegasus. Realizing that Pegasus is also the name of a constellation, Batman has Robin guide him to the proper constellation while the signs of Orion and Taurus attack him.
Finally having made his way through the virtual landscape, Batman finds Gordon is inside a "Baxter's Puzzle Box." Robin is confident he can help Batman open it in less than the minute that they're given. However, Riddler cuts off the feed so Batman has to work on his own. Batman, remembering Robin's previous comment about the Baxter Box takes advantage of the world's "virtual reality" aspect and morphs his hands into sledgehammers, trying to break the box apart.
However, the Riddler responds by stopping Batman and putting the box back together. Batman retaliates by duplicating himself and continuing his work. Riddler duplicates himself to even greater numbers that Batman does. Unfortunately for Riddler, with his consciousness ultimately spread across thirty-two bodies, he no longer has the concentration to keep his world together, and it begins to collapse.
Batman then gets Gordon out, and realizes that Riddler left a clue as to where he is. They find him inside the "World's Fair Exposition" ("If the planet were equitable, I'd still have my old job".) Unfortunately, Riddler did not escape in time, and is found a mind-wiped vegetable.