In a seemingly empty 1980s style hotel, pre-recorded music plays on the loudspeaker. A police officer, Lucy Hayward, finally approaches a door, opens it, and finds a clown inside. The last one left, she continues on to another door and finds a photographer waiting for her. He takes her picture and Lucy has a brief flash of herself as a child. Lucy quickly closes the door, realizing that she didn’t know what was inside the room until she saw it, and then wonders how she thought it could have been anything else. In the next room, Lucy hears running water and sees a gorilla come charging out of the bathroom. She closes that door as well and cowers in the hallway.
Somewhere in the darkness nearby, a creature begins to awaken.
Lucy writes down on her pad that the gaps are getting shorter and the same thing happened to the others. She starts writing down the words “praise him” and says that she’s happy now. Some huge beast rounds the corner and advances on the smiling Lucy.
The Doctor, Amy, and Rory arrive in the hotel and the Doctor is thrilled to be there. He informs his companions it may be the most exciting thing he’s ever seen, and explains that someone made it to look like Earth and the craftsmanship is amazing. He figures that they’ve been yanked off-course and suggests that colonists may have done the work. On the walls are photos of humans and aliens, all with a short descriptive phase beneath it. One of them is of Lucy Hayward, with the words “That brutal gorilla” beneath.
They go to the front desk and ring the bell, and two humans and an alien charge out. One of the humans, a medic named Rita, realizes that the Doctor and his companions are as surprised as they are. The Doctor identifies the alien, Gibbis, as a Tivoli from the most invaded planet in the universe. The third human is Howie Spragg, a blogger. The three of them explain that the walls and rooms move as if the hotel is alive. The Doctor turns off the music, opens the front door, and discovers a solid wall beyond. Rita informs them that the rooms have bad dreams in them, and that none of them know how they came there.
The Doctor takes them back to the TARDIS to escape, only to discover that it’s gone. The music comes back on by itself and he admits that it’s bad. When the Doctor asks if there’s anyone else, Rita tells them that there’s Joe Buchanan, but he’s tied up: literally. They take the trio to the bar where Joe is tied to a chair and surrounded by laughing ventriloquist dummies. The dummies stop laughing and turn to watch the Doctor and the others, and Joe tells them that they’re all going to die that. He says that “He” has forgiven him and that soon He will feast. When the Doctor asks what He is waiting for, Joe says that they were still raw. The Doctor notices that Joe has several good luck charms on him, while Joe tells them that there is a room there for everyone, even the Doctor. Joe explains that he used to fear the ventriloquist dummies but now he enjoys them, and laughs with them. When Joe tells them that they should go and that He will be there soon, the Doctor gets a cart and takes Joe with them.
Back in the lobby, the Doctor tries to work out what’s going on. He finally tells everyone that they’ll search for the TARDIS and that they should stay together and not enter any rooms. When Rita wonders what Joe was talking about, Joe laughs and tells them that someone is coming to kill them. They tape Joe’s mouth shut and start searching, carting him along. As they go, Howie suggests to Rory that they’re in Norway as part of a plan by the U.S. government to build secret cities against the threat of Earth’s collision with another planet. A door opens and a P.E. teacher emerges and starts chastising the Doctor. He goes back into the room and slams the door. Meanwhile, Howie opens a door and finds girls inside, laughing at him. Howie hears a thought-message, “Praise him,” and tells the Doctor to close the door. He insists that it’s a CIA plot and the Doctor encourages him to believe that rather than give in.
The group continues their search and the Doctor notices scratch marks on the ceiling. Amy finds the note paper that Lucy left behind while Rory discovers a fire door. Before Amy can read the paper, they hear a growling noise. The group splits up to hide. Rita wheels Joe into a room and finds her father there, condemning her for her B in mathematics. Sobbing, she apologizes. Meanwhile, the Doctor yells to Rory, who is still examining the fire door. Rory enters the room with the others and finds two Weeping Angels waiting for them. As Gibbis hides in the wardrobe, the lights flicker and the Angels advance on the others. The Doctor realizes that they’re not real and tells Amy that they are her bad dream. He has her focus on him.
Outside in the hallway, the beast moves through the corridors. The Doctor hears it and insists on looking outside to see what it is. He looks through the peephole and the creature spots him.
In the room with Rita, Joe panics and his ropes untie themselves. He runs out into the hallway and invites the creature to come to him, saying “praise him.” When the Doctor emerges, he sees the creature hauling Joe away and runs after it as the walls alter around him. He finally finds one of Joe sitting against a wall, dead.
The group barricades themselves in at the bar and Gibbis tells Amy that whatever is there wants to kill them, not just enslave them. She tells Gibbis that the Doctor has never let her down even when she was a child, and that he’ll save Gibbis as well. Gibbis points out that if the Angels were meant for him, then her room is still out there. Meanwhile, the Doctor tells Rita that Joe simply died for no obvious reason, as if the spark of life was extinguished. He’s impressed that she’s made a cup of tea for him and Rita suggests that they might be in Hell, even though she’s not afraid. Amy examines Lucy’s notepaper and shows it to the Doctor. She talks about how she saw a gorilla from a book she read as a child and how her fears are coming closer together. Lucy finally was happy to accept what was happening to her and ends with “praise him.”
Howie, toying with the silverware, blurts out “praise him” and can’t stop. The creature hears him and approaches the bar. The Doctor finally deafens everyone temporarily with his sonic screwdriver. Gibbis suggests that they sacrifice Howie and hope that satisfies the creature. Rita volunteers to stay with Howie while the others escape, but the Doctor says that they’re staying together. He tells Gibbis that he uses cowardice to survive, but promises the alien that today no one else dies.
The Doctor then tells Howie that when he is next possessed, he’s going to ask some questions and he wants Howie to answer them. After a few seconds the blogger is possessed and the Doctor asks why the creature isn’t possessing the rest of them. Howie explains that they all have distractions and they should let it go, and that he’s happy that they’re all going to die. The Doctor calls the others aside and explains that the creature feeds on their fears, and they have to resist... and then capture the creature.
Later, Howie calls out from the spa that he wants a glorious death. As the others prepare, the creature goes after Howie. Amy and Rita hide in a nearby room and ignore the sad clown sitting on the bed. The creature bursts into the spa and Rita and Amy lock the door behind it. Rory bars the other door while inside the spa, the Doctor turns off the lights. The creature searches the room and discovers that Howie’s voice is coming in via the speaker. Howie himself is taped to a chair and left next to the transmitter at the lobby desk.
The Doctor cuts the transmission and Howie snaps at Gibbis, who is watching him. He then invites Gibbis to listen to him. Meanwhile, the Doctor has set up a number of mirrors to confuse the creature and tries to talk to it. He realizes that it’s saying that the hotel is a prison.
Howie tells Gibbis that the alien should hand him over just as he wants.
The creature tells the Doctor that they’re not yet “ripe,” just as Joe said earlier, and that it has lived so long that even its name is lost. The Doctor realizes that it wants everything to stop because it’s just instinct. He asks it how to fight, but Howie gets free and calls to the creature to kill it. It smashes out of the spa past Rory and the Doctor goes after it. He finds Howie’s shattered glasses and continues the pursuit.
Amy, possessed, goes to one of the rooms, Number 7. She starts to go in as the words “praise him” echo in her head, but Rita stops her and asks what she saw. Amy insists that she didn’t see anything and leads her away.
The Doctor finds Howie, dead, and puts his glasses in his hand. Amy, Rita, and Rory arrive, and Gibbis cautiously steps out. The alien insists that Howie got free and overpowered him, and suggests that the creature will leave them alone. Disgusted, the Doctor joins the others and walks away. Back in the hallway, they discover that Howie’s photo is on the wall with the others. The Doctor asks Rory if he’s found his room yet and Rory says that he hasn’t. He then tells the Doctor that Howie recently conquered a speech impediment, and reminds his friend that not all victories are about saving the universe.
The Doctor checks on Rita and makes sure that she’s not panicking. He says that he plans to save them all and she asks why. The Doctor explains that he brought them there and that he tempted them with the idea of traveling through all of time and space. He promises Rita that he’ll take her with him when they escape, and then notices that the surveillance cameras are working. As the Doctor runs off, Rita looks at the camera, says “praise him,” and then snaps out of the momentary possession.
The Doctor searches the hallways and finally finds Room 11: his room. He looks inside, says, “Of course,” and closes the door and puts the Do Not Disturb sign up. The Doctor then goes to the security monitor room and sees Rita going off on her own. He calls the room that she’s passing and Rita hesitates, and then goes in and answers it. The Doctor asks if she started to praise Him and she nods. When he asks her to come back, Rita refuses and asks him to do her one last favor. As Amy and Rory enter the monitor room, Rita asks the Doctor not to witness her overtaken by the rapture, and to remember her the way she was. As the creature approaches her, Rita says that she wants peace, thanks the Doctor for trying, and hangs up. She then turns and faces the creature, smiling, and the Doctor turns off the monitor.
Once they bring Rita’s body back to the bar, the Doctor screams in frustration and then sits down. He tells the others that despite the fact that the creature supposedly feeds on fear, Rita was calm and brave. As the Doctor tries to work it out, Gibbis points out that thinking things through is all he’s done and they keep dying. Amy insists that the Doctor will save them and he realizes that it’s not fear, it’s faith. Howie had faith in conspiracies, Joe believed in lucky charms, and Gibbis believes that invaders will arrive to control his life. Each person felt fear and fell back on faith, following the Doctor’s advice to draw on something greater. It didn’t want Rory so it kept showing him the fire door, the way out. The creature wants Amy because of her faith in the Doctor. Rory asks why the others lost their faith and the Doctor realizes that the creature needs to convert their faith so they can consume it.
Amy starts to give in to the creature’s influence as it approaches. They run and the creature pursues them. Amy hesitates, staring backward in awe, and the Doctor and Rory grab her and carry her with them. They lock themselves in a room and find a young Amelia Pond waiting for them, her bag packed. Rory tries to hold the door shut while Gibbis cowers in a corner and Amy collapses to her knees, sobbing. The Doctor tells her that he’s nothing he can do to save her: he’s robbed her of her childhood and led her to her death. Worst of all, he knew it would happen all along but took her with him anyway.
The creature bursts into the room as the Doctor tells Amy to forget her faith in him. He admits that he was vain and just wanted her to adore him, and that it’s time for her to stop waiting. The creature backs out of the door and collapses, fatally weakened by its hunger. As the lights flicker, the Doctor goes to it and comforts it in its dying moments. The “hotel” disappears, revealing a black projection grid. The Doctor explains that they’re aboard an automated prison ship, designed to travel between planets and capture people to provide the prisoner with food. The creature was worshipped as a god until the inhabitants realized it was a false god and imprisoned it. The program developed glitches and became stuck on the fears of its previous victims.
Amy asks the Doctor why the ship took him and what he believes in. He avoids answering the question and goes to the dying creature. The Doctor translates its words and informs the others that it is saying that after centuries of drifting in space, caught in an ever-shifting maze and steeped in the blood of the innocent, death for an ancient creature is a relief. He takes its hand and the creature tells him that it wasn’t talking about itself.
The Doctor drops off Gibbis and then lands the TARDIS on Earth. He tells the couple that he has a flat and a new sports car for them, Rory’s favorite. Rory is eager to accept the car, but Amy asks the Doctor if he’s leaving. He assures her that he’ll be back someday, but it’s best that he leave while she’s still breathing. As the Doctor goes back to the TARDIS, he tells Amy that there may be a bigger, scarier adventure waiting for her in the flat. She asks if it can all end like this after everything they’ve shared, but the Doctor says that the alternative is standing over her broken body. Amy hugs him, crying, and then tells him to tell her daughter to visit sometime. The Doctor tells her to look after Rory and Amy tells the Doctor to look after himself. Amy watches as the TARDIS dematerializes. Rory comes out and asks what the Doctor is doing, and Amy tells him that the Doctor is saving them.
And somewhere in Time and Space, the Doctor travels alone.