When the Doctor arrives in Victorian London he finds a dinosaur rampant in the Thames and a spate of deadly spontaneous combustions.
A dinosaur materialises in Victorian London and spits out the TARDIS onto the banks of the river Thames, from which emerges the freshly regenerated Twelfth Doctor—suffering from post-regenerative trauma—and Clara Oswald. They are greeted by the Paternoster Gang, consisting of Silurian Madame Vastra, her human maid and wife Jenny, and Sontaran butler Strax. Vastra instructs the police on how to calm and contain the dinosaur and takes the Doctor and Clara to their residence. While the Doctor rests, Vastra confronts Clara about her prejudiced attitude to the Doctor’s changed face. Clara admits that she is struggling to adapt to the new Doctor, due to his stark difference to the old one, particularly his apparent age. The Doctor awakens to hear the dinosaur’s pleas for help. He leaves the house, gamboling along London’s rooftops and stealing a horse to reach the dinosaur. He calls out to assure the creature that he will return it to its proper time, just before it spontaneously combusts. The Doctor then joins Clara and the Paternoster Gang, who have followed him to the river, and learns from Vastra that this is not the first recent incident of spontaneous combustion. The Doctor spots an unfazed man across the river and jumps into the water to investigate. Clara returns home with the others to start their own investigations, hoping they will cross the Doctor’s path.
The Doctor, still somewhat addled, roams the back streets for answers the next morning, questioning how his body chooses a new face during regeneration. Both Clara and the Doctor find a message reading “The Impossible Girl” in a newspaper, directing them to meet at a specific restaurant. They reunite, but learn that neither planted the message for the other, as they had both assumed. They discover that the room is filled with humanoid robots that prevent them leaving. They are then descended into a lair where they see the man from the river surrounded by other idle humanoid robots. Observing mismatched body parts, the Doctor surmises the man is a long-lived cyborg, but in an unusual sense. It is a robot trying to make itself human by replacing its mechanical parts with biological ones taken from spontaneous combustion victims, including the dinosaur. The robot’s own ‘face’ is only half-covered with skin, exposing part of its ‘skull’s’ mechanisms.
The Doctor seemingly abandons Clara after escaping himself, just as the Half-Faced Man and the other robots begin to awaken. Recalling earlier advice he’d given upstairs, Clara holds her breath to hide herself from the robots. However, she is soon captured and taken to the Half-Faced Man, who questions her about the Doctor’s whereabouts. Upon Clara’s prompting, he reveals that he is trying to reach the “promised land” by prolonging his life via parts replacements. The Doctor returns for Clara, having actually disguised himself as another of the robots. They signal the Paternoster Gang, who arrive and fight the robots with Clara while the Doctor chases the Half-Faced Man back to the restaurant.
The Half-Faced Man deploys his “escape pod” — in reality, a hot-air balloon made of human skin — lifting the restaurant into the sky with him and the Doctor inside. The Doctor discovers that the Half-Faced Man and parts of the restaurant are from the SS Marie Antoinette, the sister ship to the SS Madame de Pompadour (“The Girl in the Fireplace”). The Doctor claims that the Half-Faced Man has replaced his components so many times that he no longer exists in his original form and that he secretly wants to end his existence. He then warns him that he will either have to kill himself, or the Doctor will be forced to kill him to protect the humans. Clara and the Paternoster Gang are nearly overwhelmed by the other robots when they see them go lifeless. The Half-Faced Man is then shown to be impaled on the spire of Big Ben.
After regrouping, Clara finds that the Doctor and the TARDIS have vanished. Vastra later assures her that the Doctor will return, pointing out that Clara — the person who knows the Doctor best — is already prepared to leave. The Doctor does reappear, revealing a new TARDIS control room and his new outfit. He asks Clara if she wants to continue travelling with him. Clara, however, expresses misgivings about the new Doctor’s character and is unsure about continuing with him. A phone call from the Eleventh Doctor to Clara, made moments before his regeneration from his perspective, encourages her to stay.
In the epilogue, the Half-Faced Man awakens in a beautiful garden and meets Missy, a mysterious woman who claims the Doctor as her boyfriend. She tells him that he has reached the promised land at last.