Photographer Adam Stanheight awakens in a dilapidated bathtub, with his ankle chained to a pipe. Across the room is oncologist Lawrence Gordon with a corpse between them holding a revolver and a microcassette recorder. Both men find a tape in their pockets, and Adam retrieves the recorder. Adam’s tape urges him to escape, while Lawrence’s tape tells him to kill Adam by six o’clock or his wife Alison and daughter Diana will be killed and he will be left to die. Adam finds a bag containing two hacksaws inside the toilet, which they try to use to cut through their chains, but Adam’s saw breaks. Lawrence realizes the saws are meant to be used on their feet, and identifies their captor as the Jigsaw Killer, whom Lawrence knows of because he was once a suspect.

Flashbacks reveal that Lawrence, while discussing the terminal brain cancer of a patient named John Kramer, was approached by Detectives David Tapp and Steven Sing, who found his penlight at the scene of one of Jigsaw’s “games”. Lawrence’s alibi cleared him, but he agreed to view the testimony of heroin addict Amanda Young, the only known survivor of one of Jigsaw’s traps who believes the killer helped her.

In the present, Alison and Diana are held captive at home as their captor watches Adam and Lawrence through a hidden camera. The house is simultaneously watched by Tapp, having been discharged from the police and becoming obsessed with the Jigsaw case, eventually finding Jigsaw’s warehouse using the videotape from Amanda’s game. There, he and Sing apprehended Jigsaw and saved a man from a drill trap. However, Jigsaw escaped after slashing Tapp’s throat and Sing was killed by a shotgun trap. Convinced that Lawrence is Jigsaw, Tapp has continued to stalk him.

In the bathroom, Lawrence finds a box containing two cigarettes, a lighter, and a one-way cellphone, and recalls his abduction in a parking garage by a pig-masked figure. He and Adam stage Adam’s death with a cigarette dipped in the corpse’s poisoned blood, but the plan fails when Adam is electrically shocked through his ankle chain. Adam recalls his own abduction: in his photo development room when the power went out, he found a puppet and was attacked by the same pig-masked figure. Alison calls Lawrence at gunpoint and tells him not to trust Adam, who admits that he was paid to take photos of Lawrence, many of which were in the bag containing the hacksaws. Adam reveals his knowledge of Lawrence’s affair with one of his medical students, whom he had visited the night he was abducted; revealing why Lawrence is being “tested”. After Adam describes the man who hired him, Lawrence realizes it was Tapp. Adam finds a photo he did not take, of a man staring out a window of Lawrence’s house, whom Lawrence identifies as Zep Hindle, an orderly at his hospital. As the clock struck six, and Lawrence still hadn’t managed to kill Adam, Zep moves to kill Alison and Diana.

Alison frees herself and fights Zep for his gun, after he calls Lawrence. The struggle attracts Tapp’s attention, and he saves Alison and Diana and chases Zep to the sewers, where he is shot in the chest after a brief struggle. Lawrence, only aware of gunshots and screaming, is shocked and loses reach of the cellphone. In desperation, he saws off his foot and shoots Adam with the corpse’s revolver. Zep enters the bathroom to kill Lawrence according to “the rules”, but Adam, having survived, bludgeons Zep to death with the toilet tank lid. As Lawrence crawls out of the room to try and find help, Adam searches Zep’s body for a key and finds another tape, which reveals that Zep was another victim following rules to obtain an antidote for a slow-acting poison he was given. As the tape ends, the corpse rises and is revealed to be John Kramer, the real Jigsaw Killer. He tells Adam that the key to his chain was in the bathtub. However, Adam realises that the key had gone down the drain when he had first woken up. Horrified, Adam attempts to shoot John with Zep’s gun, but John shocks him with a remote. John shuts off the lights, and yells “Game Over” before sealing the door and leaving a helpless Adam to die.