The only building on that part of the moon’s surface is the Moonbase, a weather tracking and managing station staffed by an international crew managed by the bullish Hobson. They are using a gravity machine called the Gravitron to control the Earth’s weather. When the time travellers arrive, the Doctor ingratiates them and does detective work because some of the crew have been collapsing in comas with a strange virus. International Space Control responds to the crisis by quarantining the Moonbase. The station doctor, Evans, was the first one to get the disease, and in a delirium talks of a silver hand but immediately dies of the disease.
Another of the Moonbase crew, Ralph, has disappeared in the food stores, and the Moonbase radio transmissions are being monitored from somewhere else on the moon. Jamie has been placed in the sickbay where, feverish and delirious, he begins mumbling about a “Phantom Piper”, a figure which Jamie believes appears to a McCrimmon before he dies. While attending to Jamie, Polly sees a large figure leave through the door. When Hobson, the Doctor, Ben, John and Nils arrive to collect Evans' body, it has disappeared. They then leave to investigate where this 'piper' is. Polly goes to get water, and Jamie wakes up to see the 'piper' advancing on him.
The 'piper' ignores Jamie, as he doesn't have the disease, so he steals another patient and leaves. Polly comes back in just as the figure is leaving and recognises it as a Cyberman, and the Doctor realises their old enemies are stalking the Moonbase and taking the patients' bodies. Hobson brushes away the cyber-story, believing they died out years ago. He gives the Doctor 24 hours to discover the cause of the virus, or else he and his companions must leave the moon.
While Hobson deals with the Gravitron, which is becoming difficult to control with fewer staff, the Doctor focuses on the cause of the viral disease. In the sickbay, Polly and Jamie are attacked by a Cyberman, which stuns them with electricity from his hand and leaves with another patient's body.
The Gravitron isn't working because some antennae on the Moon's surface are broken. Jules and Franz go out to fix them but are ambushed by two Cybermen and beaten to death. The Doctor can't work out the cause of the disease and is ordered to leave by Hobson. Polly makes some coffee and another crew member gets infected. The Doctor works out that the neurotropic virus has been spread through infected sugar from the food stores and is an organised scheme to destabilise the crew. A Cyberman who had been posing as a patient in bed reveals himself and aims his gun at them.
Another Cyberman emerges and kills Bob when he tries to attack the other with a metal bar. The Cybermen recognise the Doctor and use their weapons to take control of the central control centre of the Moonbase while confining Polly and Ben to the sickbay. The Cybermen reveal that they want to use the Gravitron to destroy all life on Earth by altering the weather.
On board the cyber-ship Evans, Jules and Ralph are conditioned to obey the Cybermen like zombie slaves. They are taken to the base and are sent into the heart of the Gravitron to subvert the machine. The Cybermen have been entering and leaving the base using a tunnel that goes into the food stores, explaining the drops in air pressure.
Using fire extinguishers, nail varnish remover and other objects that dissolve plastic, Ben, Polly and a recovered Jamie lead a fightback from their incarceration in the medical wing. The three Cybermen in the initial attack force are destroyed.
Benoit goes outside to see what happened to Jules and Franz. He only finds their spacesuits, and is chased by a Cyberman. Ben puts some of the solvent in a bottle and goes out. He then throws the bottle at the Cyberman's chest unit, killing it and saving Benoit. The crew block off the hole in the food stores to prevent more Cybermen entering. The cybership is located, but a large squad of Cybermen start advancing on the Moonbase.
They advance on the Moonbase through the vacuum of the Moon’s surface. Two Cybermen on the surface damage the aerial, preventing the Moonbase from contacting Earth; however, a relief ship is on the way. The Cybermen use radio beams to reactivate their zombies inside the base, who infiltrate the Gravitron and use it to deflect a relief ship sent by Earth into the sun. A hole is blasted in the wall, which depressurises the base, but Hobson and Benoit use a coffee tray to plug the leak. The depressurisation deactivates Evans and the other zombies.
Two more cyberships arrive. The Cybermen already on the surface erect a large laser cannon and threaten to blow the base open unless the entry port is opened within 10 seconds. They fire, but the beam is deflected by the Gravitron, so the Cybermen pack the cannon away. Another large squad from one of the other cyberships take up positions around the base. With the help of Hobson, Polly and Benoit, the Doctor points the Gravitron at the lunar surface, which blasts the Cybermen and their ships into space.
As Hobson and his team reorient the Gravitron to its proper use, the Doctor and his companions slip away. Back in the TARDIS, they dematerialise and then activate the rarely used time scanner to reveal a monstrous claw waving around.
The working titles of this story were Cybermen and The Return of the Cybermen. It was commissioned before the last episode of The Tenth Planet was broadcast, to take advantage of the strong positive response to the Cybermen. When Pedler was commissioned to write a second Cyberman story, one of the requirements was that the story should have only one large set and a limited number of smaller sets. The first draft of the script was written before it was decided that Frazer Hines would be a regular cast member. As a result, the character of Jamie had to be worked into a script that didn't have much room for him. So in the first two episodes, Jamie spends much of the time in the sickbay. In the last two episodes, some of Ben's dialogue was given to him.
The first 3 Episodes were recorded on successive Saturdays at Doctor Who's then regular home of Riverside 1, but for Episode 4 it moved back to Lime Grove D. A final clip, used to carry the story into the subsequent adventure, The Macra Terror, was filmed separately during the making of that story, as the Macra prop was too large to be brought into the studio.
This story is also the last story to use the original title sequence that had been in use since the first serial; the next serial introduced a new sequence with different howlaround patterns that incorporated Troughton's face.
This story features the debut of actor John Levene (uncredited) as a Cyberman. Levene would return as a Yeti in The Web of Fear, and would go on to play the regular character Sergeant Benton. John Rolfe had previously appeared in The War Machines and would appear again in The Green Death. Alan Rowe was cast as Doctor Evans, an early victim of the space plague and also provided the voice of Space Control. He later appeared in The Time Warrior, Horror of Fang Rock and Full Circle.