Immediately from the ending of Frontier in Space, the Third Doctor has been gravely wounded after being shot by the Master. Jo Grant manages to help the Doctor into the TARDIS, where he uses the telepathic circuits to send a message to the Time Lords before he collapses. Delirious, he tells Jo that he may be asleep for a while, and falls into a coma, his body temperature dipping so low that frost appears on his skin and both his hearts only beat once every ten seconds. Jo dictates into the TARDIS log, a portable recording device, that she has seen this healing state before (The Dæmons), and also that the TARDIS is moving, apparently being controlled remotely by the Time Lords. When the TARDIS comes to a stop, Jo activates the external scanners, only to see some plants outside block the viewer by spraying a thick sap-like liquid at it. With the Doctor still catatonic, Jo leaves the ship to explore the surrounding jungle. The plants spray sap on her as she walks by, and a bit of it gets on her exposed hand.
As Jo explores, the TARDIS is rapidly being covered by plant sap, which is hardening into a shell around it. When the Doctor awakens, he finds himself sealed in and the oxygen in the TARDIS cabin rapidly being used up. Activating the emergency oxygen supply, he discovers the tanks almost empty, and starts to suffocate from lack of air. Jo, in the meantime, discovers a spacecraft in the jungle with a dead pilot. She is found by two others in the same uniform — Taron, who appears to be the leader, and Vaber, who has a surly disposition. Taron is intrigued when Jo tells him about the TARDIS. The trio are joined by another crewmember, Codal, who warns them that a patrol is approaching. Taron tells Jo to hide in the spacecraft while he and the others find her friend. Jo hides in a storage cupboard while an invisible entity enters and searches the craft. She escapes discovery, but a fungoid growth has appeared on her hand and is starting to spread.
Taron and his men find the TARDIS and chip the hardened sap from its doors, managing to drag a nearly asphyxiated Doctor out into the open air. The Doctor thanks them and notes that he finds them familiar. When the men explain that they are from the planet Skaro, the Doctor recognises that they are Thals and tells them he was on Skaro many years ago (The Daleks). The Thals are skeptical when he claims to be the famous Doctor of Thal legend, but he gives them enough details that mollify them for the moment. Taron tells the Doctor that he has been infected by a fungus carried by the sap, and treats him with a spray. It would have engulfed and killed him if Taron had not treated the affected area. They are on Spiridon, a planet where the plant life is more animal than vegetable, with creatures hostile to everyone, including themselves, and extremes of day and night temperature. The Thals are the only survivors of a military expedition that was sent here. Taron orders a halt of their progress through the jungle as they hear a sound of something breaking down, but nothing is seen except a circular depression in the ground. Giving the Doctor another spray can, Taron tells him that he will see what they are up against. The Doctor sprays the seemingly empty air before him, and it reveals the outlines of a Dalek.
The Dalek, as shown in the picture, is inactive, dead from what the Thals call "light wave sickness". The Spiridons, the dominant species on the planet, have the ability to generate an "anti-reflecting light wave" which the Daleks are trying to duplicate. However, it takes a tremendous amount of power and cannot be sustained for long. The Spiridons have been subjugated by the Daleks, and forced to act as their slaves, but there are no more than twelve Daleks on the planet. Back in the spaceship, Jo has passed out as the fungus spreads across her forearm. An invisible Spiridon enters the spacecraft and takes her away.
A Spiridon patrol comes across the Thals and the Doctor. Codal leads them away from the others, but is captured. When they make it back to the craft and find the TARDIS log on the ground, the others find two Daleks about to destroy the ship. Believing Jo is still inside, the Doctor steps forward and begs the Daleks to stop, but the patrol shoots him with a stun ray. The Doctor watches helplessly as the spacecraft is blasted to pieces. Taron and Vaber manage to remain hidden, and go off to retrieve the supplies for their mission on Spiridon.
The Doctor is taken to the Dalek base for interrogation and put in the same cell as Codal. The Doctor tries to use his sonic screwdriver to open the cell door, but to no avail. He and Codal then conceive of modifying the components of the TARDIS log to emit a radio frequency that will jam Dalek control impulses. Meanwhile, Jo is being cared for by the Spiridon who found her. His name is Wester, and he is one of a group of his people who are trying to fight back against the Daleks. He cures her of her fungal infection with a salve, and tells Jo that the Doctor and Codal have been captured and taken to the Dalek base. Jo is determined to try to free them, even though Wester says that if the Daleks use them for their experiments, they are better off dead.
Vaber and Taron find the explosives that they hid earlier. Vaber wants to attack the Daleks now, and accuses Taron of being overcautious and cowardly when Taron refuses. Vaber draws his gun and threatens to shoot Taron if he does not hand over the explosives, but before things can get out of hand the heat and roar of another spacecraft rushes over their heads. It is another Thal vessel, but the entry angle was too steep, and their weapons were lost in the crash that followed. Only three Thals have survived — two men, Latep and Marat, and a woman, Rebec. Taron is not happy to see Rebec here, as she happens to be his lover. Rebec tells him that they intercepted a message to Dalek Supreme Command, saying that the Dalek army on Spiridon was now complete: a force of not a dozen, but ten thousand Daleks.
Jo and Wester see fur-wearing Spiridons entering the Dalek base, carrying crates of vegetation. The Daleks are experimenting with a plant-destroying bacterium. Jo hides herself on one of the crates and smuggles herself into the base. Taron shows Rebec another feature of Spiridon — a liquid allotrope of ice that exists in the core of the planet and erupts to the surface like lava. It is used by the Daleks as a cooling system, with ice tunnels that lead into the base. Taron plans to use them to infiltrate and cause a distraction while Vaber and Latep wait by the entrance with the explosives. A Dalek is sent to interrogate the Doctor and Codal, who use the improvised jamming device on it successfully, but the device is destroyed in the process. Making their way through the corridors, they find the three Thals, who are struggling to get out of the tunnels before a molten ice eruption floods them. Jamming the shaft doors open and getting them out, all run as a Dalek patrol enters the corridor, and is covered by the molten ice rushing out of the cooling tunnel.
The rest stumble into a chamber while Marat, weakened from the cold, covers their retreat. He is exterminated by the Daleks, who find a map on his body showing where the explosives are hidden. The Doctor seals the doors with his sonic screwdriver. The Dalek Section Leader sends a patrol to find and destroy the explosives, while others are sent to get cutting equipment. Jo overhears the orders and follows the Dalek patrol out of the city. Trapped in the chamber, the Thals and the Doctor find a huge refrigeration unit, pumping excess heat up through a ventilation shaft that leads to the surface. The Doctor also discovers the Dalek army stored in an adjoining chamber, sleeping in suspended animation. Improvising a hot-air balloon from plastic sheeting, the four rise up the shaft as the Daleks break through.
A gravitational disk is sent for so that a Dalek can follow them up the shaft while another patrol is sent to the shaft's exit point on the surface. The Dalek patrol sent to find the explosives activates the timed detonators and leaves. Jo sneaks up to try and deactivate the timers, but only manages two before being knocked out by a stone from the crumbling cliff-face the explosives were hidden against. She awakens barely in time to grab the deactivated bombs and take cover before the third detonates, conveniently destroying the Dalek patrol that was sent to intercept the Thals. Meanwhile, the Thals and the Doctor reach the top of the shaft and drop a rock on the pursuing Dalek, sending it plummeting to the bottom. Making their way away from the shaft, they meet Jo, who the Doctor is overjoyed to see again, since he thought she had been killed when the Thal ship was destroyed. The Doctor explains to Jo that his telepathic signal was to tell the Time Lords the location of this planet — he had learned that there was a Dalek invasion force here while on the planet of the Ogrons. The Time Lords then steered the TARDIS here. Latep and Vaber also rejoin the group. They had thought the others were killed in the ice eruption, and were about to assault the city when they found one of their bombs was a dud and the others destroyed by the Daleks. Jo shows them the two bombs she managed to rescue.
The group decide to hide in the Plain of Stones, an area of Spiridon with rocks that absorb heat from the sun by day and discharge it at night. They manage to avoid a combined Dalek/Spiridon patrol as night falls and the temperature drops, and the Doctor notices the Daleks seem to be moving slower than usual. In the Dalek base, a Dalek reports to the Section Leader that the bacteria will destroy all plant life within a day, and unimmunised life forms within an hour. It will be ready in half a Spiridon day. At the Plain of Stones, Vaber and Taron come to blows again about when to take action. During the night, Vaber steals the two bombs and sneaks away from the camp site. Taron and Codal go in pursuit as the others huddle around the campfire, surrounded by animal forms with eyes glowing in the darkness. Vaber is caught by the Spiridons, who bring him to a Dalek patrol as Taron and Codal watch, hidden and disguised in the fur coats the Spiridons wear.
When the Daleks try and force Vaber to lead them to the Thals, Vaber breaks away and is exterminated. Taron and Codal use this distraction to grab the two bombs and vanish into the forest. The Daleks, in the meantime, have developed an immunisation process against the bacteria, and orders are sent out for all Daleks and Spiridon slaves to return to the base for immunisation before the bacteria is released. On the Plain of Stones, Wester shows up to tell Jo that the Daleks have developed the deadly bacteria, and that he is going to try to enter the base and stop its release. The Doctor devises a plan using nearby pools of molten ice. Deducing that the ice slows and even stops the Daleks from functioning, the group lure a Dalek patrol to them, and manage to push the two Daleks into the pools, the sudden drop in temperature killing them. Taron, Codal and the Doctor dress up in Spiridon furs while Rebec sits in the emptied Dalek casing so they can enter the base unmolested with one of the bombs. Latep and Jo will enter the city via the ventilation shaft with the other bomb, in a two-pronged attack. As the first group enters the city, they see Wester entering the bacteria preparation chamber under the pretence of delivering a report. Wester releases the bacteria into the sealed room, sacrificing himself but ensuring that the room cannot be unsealed without killing the other Daleks. The group try to move deeper into the base, but one of the Thals' boots is spotted by a Dalek, who sounds the alert.
The group flees down the corridors, making their way back to the cooling chamber. Once there, the Doctor asks Rebec and Taron to barricade the entrance while he finds a way to keep the Dalek army from reviving. He and Codal decide to set an explosive in the wall of the chamber containing the Dalek army, which is slowly coming to life. In the meantime, the Dalek Supreme, a member of the Dalek Supreme Council, has arrived in a spaceship, to oversee the final stages of the operation, and exterminates the Section Leader for its incompetence. Jo and Latep finally arrive at the cooling chamber, and use their bomb to destroy a squad of Daleks before joining the others. As another patrol comes through, the bomb set in the wall of the chamber explodes, causing molten ice to rush out and flood the chamber, freezing the Dalek army for centuries to come. The group escapes through a ramp that leads to the surface while the rest of the Daleks abandon the base, which is filling with molten ice.
The group makes its way to the Dalek Supreme's spacecraft. The Doctor asks Taron not to glorify the story of what happened here and make war sound like an adventure. The Thals were a peaceful people and he would hate to see them become otherwise. Taron and Rebec promise, and the Thals enter the spacecraft and leave for Skaro. The Doctor and Jo run back to the TARDIS, pursued by the Dalek Supreme and the other Daleks, and dematerialise just as they open fire. The Dalek Supreme orders that operations begin to recover the invasion force and to contact the Dalek High Council for a rescue ship. The Daleks have been delayed, but will never be defeated...