The Ponds clean up at home after another long trip with the Doctor. Afterward, they discuss which life they should choose: their normal lives or their lives with the Doctor. They hear the TARDIS materialize inside and decide that they'll choose later.
Later, the couple is sleeping in bed... unaware that a small black cube has materialized in their bedroom and drifts gently down to land on their nightstand.
The next day, Rory's father Brian comes over at 6 a.m. to tell them the news: Millions of the black cubes have appeared all over London. Newscasts confirmed that the cubes have appeared all around the planet. Amy spots the Doctor examining one of the cubes across the street at the playground. He takes everyone into the TARDIS and analyzes the cubes, but all he can tell is that they're identical right down to their molecular structure. The Doctor is unhappy that he doesn't know what is going on and goes out to the Ponds' kitchen to experiment on the cubes. When Rory has to go to work, the Doctor is surprised that he has a life outside of traveling in the TARDIS. Amy explains that she's a travel magazine writer and that they both work.
As the Doctor works, Amy explains that she and Rory believe that they may have lost as much as ten years of their present time while traveling during the Doctor. Before he can respond, soldiers burst into the house, capturing Rory as he changes. Their leader, a woman, comes in and apologizes, explaining that they detected Artron energy and had to investigate given the unusual situation with the cube. She introduces herself as Kate Stewart, head of Scientific Research with UNIT, the Doctor's old organization. Kate realizes that he's the Doctor and explains that science is now in charge of the military. The only thing they have learned about the cubes is that they are indestructible. She believes that they're the result of a hostile action and the Doctor agrees, but they have no way to start a worldwide effort to coordinate their disposal unless they have evidence.
The Doctor starts watching the cube. However, after four days he goes out of his mind with boredom and asks Brian to watch the cubes while he goes off on a quick jaunt in the TARDIS. When he invites Rory and Amy, they refuse, saying that they have jobs.
The cubes have done nothing. Amy goes out with her friend Laura, who is reluctant to have Amy as a bridesmaid since she keeps disappearing. At the hospital, Rory is told the same thing by his friend Ranjit. Ranjit asks Rory to work at the hospital full-time, while Laura asks Amy to be her bridesmaid in several months. They both agree, much to their surprise. At home, they tell each other what happened and wonder if their real lives have started. The couple admits to each other that they like the idea.
Brian records himself watching a cube, and records the cube and checks it for movement when he's sleep. Rory is less than impressed but Brian insists that he has to do what the Doctor asked.
Rory is working at the hospital while a young girl in the hospital watches everything and holds one of the black cubes. Her eyes briefly glow blue. Meanwhile, two orderlies check on an elderly patient, Arnold Underwood. However, once they're alone with Peter, they advance on him and ignore his questions. He rips a mask off of one of them revealing that the man's lower face has converted into a cube. They take him away as the girl calmly watches.
Across the globe, people accept the cubes as just another part of everyday life.
Amy and Rory are celebrating their wedding anniversary with an outdoor BBQ and Amy tries to call the Doctor. She gets his answering machine and leaves a message saying that the cubes have been declared provisionally safe. The Doctor arrives with flowers in the middle of her message and takes Rory and Amy to June 6, 1890, for an anniversary weekend at the newly-opened Savoy. Unfortunately, Zygon imposters infiltrate the hotel staff and the Doctor soon finds himself fighting an alien invasion. To make it up to the Ponds, he takes them to a wedding of King Henry VIII but they end up hiding in the King's bedroom until the Doctor sneezes and gives them away.
Eventually the Doctor gets the couple back home moments after they left their party. Only Brian notices that they're wearing different clothing and he asks the Doctor how long they were gone. The Time Lord admits that they were gone for seven weeks and Brian wonders what has happened to his previous companion. The Doctor admits that some left him, some were left behind, and a very few died. He promises Brian that will never happen to Rory and Amy. After the party is over, the Doctor asks Amy if he can stay with them, admitting that he misses her, and she agrees.
Brian continues to record his observation of the cube but he soon dozes off from boredom. Meanwhile, the Doctor, Amy, and Rory watch television and eat fish fingers and custard. Brian's cube moves, startling him awake, and he checks the video recordings.
In the kitchen, a cube opens behind Rory, catching his attention. When he examines it, nothing seems wrong.
Amy is in the bedroom when another cube starts glowing. When she picks it up, it extends needles and pricks her palm, and then displays her pulse rate on the surface.
The cube in the kitchen opens briefly and Rory notices. When he tries to examine the opening, it closes and one on the other side opens.
The Doctor is in the lounge playing the Wii when a cube floats into the air in front of him. He warns it that he will defend the planet and it exudes a blaster and shoots him. He ducks out of the room and the cube accesses the Internet via the Ponds' computer. The others join the Doctor and compare notes, while Ranjit calls and tells Rory that they need him because some cubes are attacking and injuring people. As Ranjit makes the call, the young girl watches everything, still holding her cube.
Rory goes to the hospital and Brian decides to go with him to help. Kate summons the Doctor to UNIT headquarters at the Tower of London, sending him the invitation via his psychic paper. When he and Amy get there, Kate explains that all of the cubes activated at the same moment all across the world. UNIT has fifty cubes in their headquarters, each one in a separate containment cell. Each one is doing something different: some are generating emotions, some are emitting music, some are emitting flames. Kate tells the Doctor that some cubes are activating government computer systems and she doesn't know what to do. The Doctor tells her to have faith, just like her father Brigadier Lethbridge-Stewart would have.
After 47 minutes all of the cubes deactivate. The Doctor out to get some air so he can think and Amy goes with him. As they sit by the river, the Doctor wonders if she and Rory plan to stop traveling with him. Amy admits that they've gotten used to a normal life since the Doctor gave them their home, and traveling feels like running away. The Doctor insists that he's not running away from things but rather running to them, because the universe is constantly changing. When Amy wonders why he keeps coming back to them if that's the chase, the Doctor admits that they were the first thing he's seen and that they are seared on his heart, and he wants to keep coming back before they fade from his mind.
As they talk, the Doctor gets an idea and goes back inside. He tells Kate that the cubes deactivated because they have what they want: complete medical and military knowledge of all humans on Earth. The power in headquarters suddenly goes out and each cube displays a blue 7 on its side. The numbers change to 6s simultaneously and the Doctor realizes that they're seeing a countdown. He tells Kate to inform all of the world governments that the cubes are dangerous and to get rid of them as quickly as they can. He figures that the cubes waited a year to activate because whoever sent them wanted them to become an accepted part of everyday life and be taken into homes and governments. The Doctor then writes a program to try and trace the signal that must have activates all of the cubes.
The cubes keep counting down and at the hospital, Rory organizes the effort to get them out. Brian goes to get some supplies and notices the two orderlies go by with a gurney. When he asks them for directions, they turn and advance on him with large metal syringes.
Rory soon notices that his father hasn't returned and goes out into the hallway. He sees the orderlies taking Brian away on a gurney and follows them into an elevator. They disappear and Rory discovers that one wall of the elevator conceals a wormhole. He steps into it and finds himself on an alien spaceship orbiting Earth.
As the countdown reaches 2, the Doctor decides to confront a cube directly. He gets no response and the countdown reaches zero... and nothing happens at first. A panel opens in the side but there's nothing inside. He steps out, complaining that things don't make any sense. and then clutches at his chest in pain as the CCTV monitors show millions of people suffering the same symptoms of cardiac arrest. The Doctor survives since only one of his hearts has stopped, and checks his tracking program. He discovers that the cubes are draining the electrical activity in human hearts, and the activation signal came from seven different stations scattered across the world. A wormhole is also registering at the central transmitter: Rory's hospital.
Rory explores the spaceship and finds a chamber holding Brian and other missing patients. The two mutated orderlies advance on Rory, wielding syringes.
The Doctor, Amy, and Kate go to the hospital and Kate receives reports that almost a third of the world's population has suffered heart attacks. Kate goes to coordinate the world effort while the Doctor tries to find the wormhole portal. He detects signals coming from the girl and realizes that she's a droid sent to monitor the situation. He shuts her down using his sonic screwdriver but is unable to continue because he has only one functioning heart. Amy uses a fibrillator to start his heart back up and the Doctor runs off, reinvigorated.
The Doctor soon tracks the wormhole to the elevator. He takes Amy's hand and she eagerly steps through with him. They find Rory and the others aboard the spaceship and revive him. A hologram of the ship's commander, one of the Shakri, fires on them. The Doctor sends Rory and Amy to get the patients back to Earth and then confronts the alien humanoid. The Shakri says that humanity is a plague upon the planet and must be wiped out, and the Doctor admits that on Gallifrey the Shakri were considered a myth. The Shakri tells him that it serves the Word of the Tali and that it must eradicate humanity before it spreads out to the stars.
Rory and Amy come back despite the Doctor's orders and he explains that Tali is another word for Judgment Day. The Shakri says that humanity is a blight but the Doctor points out that they accepted the cubes into their homes because they were looking for something better. He challenges the Shakri to measure humanity's achievements against its failures, but it ignores him and insists that the Tali must be met. He then prepares to release a second wave of cubes and complete humanity's extension.
On Earth, Kate tries to coordinate the world governments and tells them that they must work together or die.
The Shakri insists that the Tali must be met and its image disappears. The Doctor tells his companions that it was simply a projection from the ship and then goes to the control console. He works out that he can send an energy transmission back to the cubes, jumpstarting the hearts of everyone stricken by the first wave of heart attacks. As he does so, the Doctor realizes that the backlash will destroy the ship and they get off via the wormhole just in time.
As the victims revive and are tended to, the Doctor meets with Kate. She admits that he's just as remarkable as her father told her and gives him a thank-you kiss. When she asks him to stay, the Doctor says that he has to go to a dinner date.
At the Ponds' home, the Doctor enjoys supper with Amy, Rory, and Brian. As he starts to go, he tells Amy and Rory that he understands that they have normal lives that they don't want to give up. However, Brian speaks up and says that it's the Doctor that they don't want to give up. He agrees that they shouldn't and tells Amy and Rory to go with the Doctor and save every world that they can find. The Doctor invites him along, but Brian says that someone has to water the plants and take care of things. As they leave, Amy realizes that the Shakri didn't take one other thing into account: the Power of Three.