In the final 23 days of L's life, he meets one final case involving a bioterrorist group that aims to wipe out much of humanity with a virus. The virus has an infection rate that is one hundred times the infection rate of the Ebola virus. He takes a boy he names Near, the sole survivor of its use in a village in Thailand, and an elementary school student named Maki Nikaido under his wing.
Dr. Nikaido later receives a sample of the deadly virus which destroyed that village in Thailand. His assistant, Dr. Kimiko Kujo, reveals herself to be the leader of the organization that created the virus. Dr. Nikaido, who has created an antidote to that virus, refuses to give it to her. He destroys the antidote and injects himself with the virus. She later kills him, and she is convinced that his daughter Maki has the antidote formula.
Under the pursuit of Dr. Kimiko Kujo and her assistants, Maki runs and escapes. She eventually finds L's headquarters. However, the group manages to track Maki down, forcing L, accompanied by Maki and Near, to run away with a high-tech crepe truck. They also received the help of FBI agent Hideaki Suruga during the escape.
They escape to Nikaido's research partner's lab, because they needed his help to recreate the antidote. Using Near, L manages to acquire the antidote just as the terrorists are about to take an infected Maki to the US to spread the virus. L stops the plane and gives all the infected passengers, including the terrorists (those that survived), the antidote. Maki then tries to kill Kujo for revenge, but L stops her, telling her that killing Kujo would not bring back her father. Kujo and the terrorists are then arrested, while Maki goes to the hospital and wakes up, fully cured, with her stuffed bear next to her and a recording from L telling her to have a good day tomorrow. The film concludes with L leaving Near and giving him Near's "real name".
After the end credits, L is seen back in his room eating a chocolate bar and then leaves momentarily, possibly leading to the events where he dies in Death Note: The Last Name. The film ends with the words "L Lawliet, Rest in Peace" on a black screen.