The Doctor and Team T.A.R.D.I.S arrive in 17th Century Lancashire by accident as they were trying to land around the coronation of Elizabeth I. They walk into a village's Sunday celebration but the festivities are halted by a general assembly at the lakeside where Mistress Becka Savage is ducking an accused witch named Old Mother Twiston. Despite warning the Companions not to get involved in history, The Doctor jumps into the water to try to save Mother Twiston. She drags her out of the water but the woman is dead.
Showing her psychic paper to Savage, The Doctor gains recognition as the nation's head Witchfinder. Twiston's granddaughter, Willa, is grieving her grandmother's death and Savage wants her apprehended as well but The Doctor forbids the guards touch Willa. A masked man watches from the trees.
The Doctor walks and talks with Savage who explains that she's the local landowner who metes out justice to the town. Including Twiston, she's killed 36 women and also states that horses are creatures of the Devil so she had all hers shot and horses banned from the town. Yaz heads back to the village to talk to Willa.
In Savage's hall, they discuss the witch trials she holds on a weekly basis and suddenly the masked man from the woods arrived and reveals that he is King James. When he sees the psychic paper, he identifies The Doctor as the Witchfinder's assistant and Graham as the Witchfinder General because he is a man. The King shares that he has come to help Savage with her cleansing of the town.
Yaz finds Willa burying her grandmother. As she chants, Yaz spots a mud tendril moving to grab her and yells to get her attention while grabbing a shovel and beating it to pieces.
The Doctor leads Graham and Ryan to Savage's bedroom to do some snooping. She finds a pile of handkerchiefs and Ryan finds a long-handled ax under the bed. Yaz finds them and tells them about the mud tendril. The Doctor and Yaz head back to Willa, leaving Graham and Ryan to keep Savage and the King from hunting any more witches.
The Doctor and Yaz find Willa just as she's about to run away from the village. They find out that Savage is Willa's cousin and their grandmother raised them both. The Doctor scans her when she says she's feeling sick but finds no illness. Yaz realizes that she's feeling sick because of her Granny's murder at Savage's hand. The Doctor convinces her that running away won't make her feel better but helping them end the trials might.
King James shares with Ryan why he hunts Satan fanatically.
The Doctor, Yaz, and Willa return to her grandmother's grave to investigate the mud. The Doctor puts a bit in a bottle and it suddenly animates. Meanwhile, Old Mother Twiston rises from the grave, full of sentient mud. She gestures to the bottle of mud The Doctor is holding and The Doctor gives it to her. The Mud Mother ingests the bottle. The Doctor asks questions and gets no answers until Yaz draws her attention to the other bodies that have animated.
King James' group comes running into the clear where The Doctor's group is facing off against the animated corpses. The King orders his guard to shoot the corpses and they turn on him and kill him instantly. The Doctor orders everyone to run. The corpses don't follow so Ryan, Yaz, and Graham head back to see what they're doing.
The Doctor stays with Willa, Savage, and King James to try to puzzle out the situation. When she questions Savage about what she knows, Savage accuses her of being the cause of the corpse animation. Willa is pressured to bear witness against her and The Doctor is arrested.
While the Companions track the corpses through the woods, King James interrogates The Doctor. She tries to convince him to help her but he chooses to call the guards instead.
The corpses head back to Savage's manor and the Companions follow their trail upstairs. The corpses retrieve the ax and head back out.
When Savage is preparing The Doctor for ducking, the wood of the device sparks against her hand. The Doctor notices and calls her on it and Savage promises her that she will kill all her Companions for her interference.
A distance away, the Companions hear the ducking bell and realize it must be for The Doctor and rush to the river. They arrive just as the king gives the command to duck her and Savage leaks mud from her eye. They convince the king to command the stool be brought up but Savage insists they must be sure. He gives the order again and the stool is brought up and the seat is empty.
The Doctor emerges from the water a bit downstream. She confronts Savage again. The animated corpses arrive but rather than attacking Savage, they follow her orders. Savage admits that the problems began when she cut down the old tree on the hill. She was infected with something so she turned to fanaticism and witch-hunting to save herself. Surrounded by the corpses, she finally gives in to her infection and transforms into a Morax-possessed entity. The Morax were aliens imprisoned in the hill and locked in with the tree that Savage cut down and making her ducking stool out of. Now free, they plan on infecting King James and taking over all the people on the Earth. They stun everyone at the riverside and abduct King James.
When the team revives, they prepare by taking parts of the ducking stool to make torches. Willa joins them in order to lead them up the path. They confront the Morax mob just as the Morax king manifests to infect James. The Doctor reactivates the prison, sucking all the Morax mud out of the corpses. The Morax in Savage refuses to go so King James sticks her with a torch and kills her which angers The Doctor greatly.
King James and Willa accompany the team back to the T.A.R.D.I.S. The Doctor still refuses to respond to his questions. The king asks Ryan to join him as a royal guard but he declines the offer. The king swears he'll never tell anyone about the adventure and plans on striking the name of the village off the registries in order to hide the Morax prison better. Willa plans to continue her granny's herbal care business. The team piled into the T.A.R.D.I.S. and disappears.