There is a flashback to the last episode: Mikami enters the warehouse and Light asks him how long it has been since he first wrote down everyone's names. Mikami begins counting at 35 seconds, and just before he reaches the 40, Light declares his victory to Near.
The flashback ends. Shafts of light begin to fall upon the dreary city and stream through the dirty windows of the warehouse, those within realizing that, now that the 40 second countdown is up, none of them are dead. Matsuda makes the obvious statement of such and Near confirms that it was what he was telling them the entire time. Mikami huddles over his Death Note, wondering why those in the room have not perished. Light looks on in shock as Mikami declares he has done all he's been asked to do. Lester and Gevanni seize Mikami and Near is handed the Death Note. Near reveals which names are written within the Note, and that Light's is the only one missing.
Realizing he has been backed into a corner, Light begins to panic. He yells that the entire thing was a trap, a set-up, a framing. Having lost his ability to reason in his panic, Light's accusations are counter-argued calmly by Near. He then claims he does not know Mikami, breaking his faithful follower and further shattering his mind.
Aizawa moves closer to Light, gently reminding him that he has practically confessed to being Kira. Matsuda falls to his knees, finally realizing it is all the truth, questioning why Light has done it. Mogi crosses the room to place Light in handcuffs, but Light, still trying to find a way out of the situation, pushes him away and runs to the wall, eyes wild, panting heavily; a wild animal.
Near lists off all names Light goes by, and declares that he has lost. He then makes the SPK's work known to the others. He says that while they modified the fake notebook a bit, they completely replaced the real notebook and pulls the real Death Note out of his shirt, informing Light that Gevanni duplicated the entire notebook in a single night.
As proof, Near addresses Ryuk for the first time. He then confirms with Ryuk that a page ripped out of the Death Note has the same effect as the entire notebook, and from this begins to wonder just how many times they've been duped due to that fact. Near declares once again that Light is indeed Kira.
Light knows that something is amiss, and wonders if Mikami betrayed him. Near interrupts these thoughts and makes it clear that Mello is to blame for this downfall. He flips back a page in the real Death Note and reveals that Kiyomi's name is written in it, set to die one minute after Light had already killed her. Mikami tries to justify his reasoning and Light panics more, knowing that this unnecessary action was what led to the notebook being switched.
Near explains that upon hearing about Kiyomi's kidnapping, he headed to the bank on a day he was not known for doing so. Gevanni followed him and discovered the real Death Note in the safe deposit box. It was because Mello forced this action from Mikami that Near learned of the fake notebook. Near says that while alone neither of them could surpass L, together they were greater. Near then invites Light to "talk your way out of this one."
Light laughs hysterically and suddenly stops, and admits that he is Kira, the god of this new world. He explains the reasoning behind all of his actions as Kira: that he was the "only one that could do it." He knew that what he was doing was a crime, but it was the only way to correct the rotten world.
Near flat-out denies his claims, reminding him that he is nothing but a murderer possessing the deadliest weapon known to mankind. Light criticizes himself for believing they would understand him and tries to bluff his way into making them believe the notebooks present are fakes, in order to buy time to write on the piece of Death Note in his watch. They catch on just as the compartment opens and Matsuda, still on his knees, fires his gun at Light. Matsuda asks what it was that Soichiro died for, still pointing the weapon at Light. Kira responds that those crowned in such a way with justice will always lose and asks if Matsuda is content with living in such a society.
A moment of silence follows, and Light attempts to write Near's name in his own blood on his final scrap of Death Note. Matsuda shoots four times more, sending Light careening into a puddle on the warehouse floor. Driven to tears and emotionally unstable, Matsuda stands over Light and fires again, the bullet missing Light's head by centimeters as Matsuda is restrained by the rest of the task force.
Mikami looks at his fallen God, struggling futilely to rise to his feet from the puddle. Light calls for help, for Mikami to write down names, but there is nothing X-Kira can do. Light then calls for Misa and Kiyomi, desperate for anyone who could help him. While the others are distracted by Light, Mikami stabs himself in the heart and bleeds to death.
While the others are distracted by Mikami's suicide, Light struggles to the door of the warehouse. Throwing it open, he is spotted by Aizawa, who shouts at him to stop. Instead, he flees. The task force starts to follow, but Near calls out for them to stop, reminding them that Light has lost either way, and with his wounds, he will not be able to go far. Aizawa responds that he will not stay, to which Near quietly agrees, giving him permission to search for Light. Aizawa and the Task Force members leave the warehouse, Near and the SPK choosing to remain.
Light runs down a narrow road between the warehouses and the reservoir opposite, clutching his arm. As he continues, he sees an image of his former, more innocent, self walking towards him, but Light continues to run past him. Atop a nearby tower sits Ryuk, watching the events unfold. Knowing his fun is over, he reminds Light of the fact that he must be the one to write his name in his own Death Note, telling him that his life is effectively over anyway, and that he will not wait for a prison stint before he can leave Earth.
Light is lying on a set of stairs in a warehouse, clearly at the end of his strength. Ryuk writes his name in the Death Note, and Light's heart attack begins. As the credits begin to roll, we see Misa sitting in a train, dressed in a Lolita outfit. Her final scene depicts her standing outside the safety barrier on the roof of a skyscraper, closing her eyes to the setting sun.
The scene changes back to Light, who is now dying. In his last moments, he sees - or thinks he sees - L standing at the foot of the stairs (though the detective's face is blocked by an overhanging beam) before his eyes close. The scene returns to Ryuk before panning up past the sunset to the night sky beyond.