Murphy is still imprisoned in an underground shrine, unconscious. Titus begins interrogating him again when Murphy comes to. He continues to ask about where he retrieved the City of Light Key, which is the sacred symbol of the Commander. Murphy explains to him thatJaha gave it to him, and explains its use. When Titus asks how this computer program ended the world, Murphy tells him that he does not have details, because on the Ark, they were told it was just countries and politics.
In a flashback, ninety-seven years ago, Becca and her assistant, Peri Gordon, work on version two of A.L.I.E. It's in a form of a chip with tentacle-like appendages, but it continuously malfunctions. Suddenly they get a transmission from Chris. He warns her that A.L.I.E. has gotten out and is on the grid. That she is hacking nuclear launch codes. The woman asks why, and Becca answers with A.L.I.E.'s supposed problem with humanity: "Too many people."
Becca tells Chris to send out A.L.I.E.'s poisoned pill virus and kill her. Chris warns her that he has already done so and she has locked him out of everything. He is ordered to seek refuge in their lighthouse bunker. Polaris Commander, Cole McAdams, enters the lab and alerts them that twenty-seven ICBMs have been launched from China and are aimed for the United States.
From their space station, Polaris, they watch in horror as the missiles approach their destinations. McAdams manages to contact his wife and daughter, but the signal is lost. The missiles from China make contact, and the United States fires back. The nukes drop on almost every major city, and the Earth is left simmering in radiation.
Back in 2150, Lexa and the Nightbloods celebrate Ascension Day. Suddenly, Semet barges into her throne room. He has Octavia prisoner, and claims that Skaikru has destroyed his village. He begs for his Commander to avenge them, and kill all of Skaikru. Clarke, Lexa, and Titus discuss the situation. Titus wants Lexa to destroy the thirteenth clan as a show of strength. While Clarke wants the Sky People to overthrow Pike themselves.
At the end of the debate, Lexa decides to call upon the armies of the twelve clans and march on Arkadia, not to attack but to blockade them and allow Skaikru to take out their leaders from the inside. However, any Skaikru found past the five-mile buffer zone will be subject to a kill order. Semet attempts to assassinate her out of rage, but Titus executes him first. Once again, he tells Lexa that blood must have blood.
In the shrine, Murphy frees himself from his bonds and tries to escape. However, the door is locked. Preparing to defend himself, Murphy steals a spear from the pod, causing the door to close where it reads Polis, the name of the capital. He sees that there is a gap between the "Pol" and "is," which is singed away. Murphy, after analyzing the cave paintings on the walls, realizes that it once read Polaris.
In a flashback of 2054, two years after the world ended, Becca is seen injecting herself with a black fluid, altering her DNA and rendering her blood a black color. In her briefcase, it is seen that there are many more vials of the black fluid. McAdams confronts Becca, having been told by her assistant, Peri, that Becca's artificial intelligence program was what destroyed the human species. The commander is preparing to dock along with the other twelve stations, to create the Ark, and angrily tells her it is being designed to ride out the nightmare that Becca created.
They will not join the Ark, which is scheduled to unite in two hours until the second A.I. is floated. Becca pleads that the A.L.I.E. 2.0 is exactly what they will need, what will save them on the Ark. She fears that the Ark will not survive with limited normal human scientists doing the calculations and that the A.I. will help them survive because A.L.I.E. 2.0 will have a biologically-based human conscience that will know humanity's "wants and needs" because it will also want and need the same things that humans will. However, the Commander is not convinced and goes with Peri to find something to float the research in. Becca, guilt-ridden and in need to make some amends for the destruction she caused, is still convinced that A.L.I.E. 2.0 will help the remains of humanity to survive and locks herself in the lab.
Back in Polis, Clarke is faced with two choices: return with Octavia to stay imprisoned inside Arkadia until Pike is defeated, or remain in Polis with Lexa, who still has feelings for her. Titus is against the latter and warns her that Clarke may become like Costia. This enrages Lexa and reassures him that she is more than capable of separating feelings from duty. He apologizes, and she says that it is Clarke's decision on whether she wants to leave or stay.
Octavia finds Indra in the capital, and attempts to convince her to come back to help them battle the Arkadians. Indra feels as if her honor has been lost, and displays this when even Octavia proves to be superior to her in combat. However while Octavia waits impatiently for Clarke to join her, Indra appears and they head back to Trikru without Clarke.
Titus returns to the shrine where Murphy is waiting to attack. Titus defeats Murphy and nearly kills him until Murphy begins to explain what the shrine actually is. He tells him about the end of the world, the nuclear radiation, and why Skaikru needed to stay in space. Murphy explains that Polaris was the thirteenth station and that the woman in the cave paintings must have escaped and landed on Earth, and was just like The 100. Titus, while doubtful, says that Becca is nothing like Skaikru and knocks him out.
In another flashback, McAdams warns Becca that the other stations are threatening to stop docking maneuvers because Polaris has not started. Alpha Station contacts Polaris and threatens to martyr them. Becca launches from the pod, wearing the commander's spacesuit. The Alpha Station destroys Polaris to send a message to the other stations and forces them to join, threatening that the same thing will happen to the other federation stations if they choose not to join.
Clarke, who has decided to leave, says goodbye to Lexa. She hopes that one day, they will owe nothing more to each other's people and will be able to live peacefully. Lexa hopes they will meet again. Before she leaves, Clarke and Lexa have sex. Afterward, Clarke examines a tattoo on Lexa's back. She explains that she got it on her Ascension Day, and each circle represents each Nightbleeder who died. There were nine participants in Lexa's conclave, but only seven circles on her back. Clarke asks what happened to Number Eight, but Lexa says she does not want to talk about it, and they begin to kiss again.
As Clarke prepares to leave with Octavia, she finds Murphy outside Lexa's sleeping quarters. He is tied up and injured, but alive. Titus pulls out a gun, saying if he kills Clarke with a Skaikru weapon, Lexa will think it was Murphy and may be so heartbroken that she will declare war and kill the Arkadians. Clarke manages to dodge the bullets, but Titus, who is not skilled with firearms, accidentally fires a stray bullet, which hits Lexa in the stomach.
Titus realizes what he has done and helps Clarke put Lexa on the bed so she can save her. She begins losing too much blood, but Lexa tries to calm Clarke and tells her not to be afraid. Titus prepares to retrieve her spirit and begs for forgiveness. Lexa simply haves him swear that Titus will never attempt to harm Clarke again, which he swears. She then tells him to do his job and serve the next commander as he served her. Clarke tries desperately to save her. Lexa is convinced that her spirit will find a new Nightblood, but Clarke only wants Lexa and not another commander.
Lexa tells Titus that she is ready, and tells Clarke that her fight is over. She also manages to tell Clarke that life is about more than just surviving. Clarke then recites the traveler's blessing to her and kisses Lexa for the last time. Lexa dies shortly after. After convincing an incredibly saddened Clarke that he must complete the ritual. He turns Lexa over on her back, where above her Ascension Day tattoo, across the nape of her neck, is the same infinity symbol that Titus was interrogating Murphy about, and the same symbol on Jaha's pills.
Vertically down the center is a scar, which Titus reopens. As blood pours out, A.L.I.E. 2.0, now sentient, emerges. Titus puts it into the sleep mode and stores it away in an old tin box. He carries away Lexa's body and alerts the Grounders that the conclave must begin and that Lexa is dead. Her spirit (the A.I. plucked from her nape) will choose the next commander. They lock Clarke and Murphy inside her chamber, and Murphy attempts to break free while Clarke stares at the black blood stains on the bed in shock.
Becca survives and lands on Earth, in the ruins of Baltimore during the nuclear winter. Her suit is breached and the radiation levels spike. The black fluid injected is presumed to counteract the effects of nuclear radiation as she was able to take off her helmet and breathe safely. Out of the debris, Becca sees humans approaching in the distance, wearing hazmat suits. She tells them that she is here to help. It is implied that she would inject these survivors with the black fluid and make them immune to the radiation as well. It is seen that on Becca's nape, crudely stitched, is the same vertical cut that must contain the same A.I.