15 years ago, a teenage girl was savagely beaten to death. Her neighbor, Frank Henson, was caught fleeing the crime scene. He was convicted for the 1998 murder of Kimberly Tolbert and sentenced to death. His execution date is now three days away. Alexis is in the courtroom as the judge denies him a stay. She pleads with her college professor that there must be something they can do. There isn't. The professor says that sometimes the good guys don't win. Unless they have a crime-solving mystery writer in their corner, that is.
Castle wants to marry Beckett…in space! This plan is just so he can get out of looking at possible wedding venues. Castle's space dreams get put on hold when Alexis stops by. She's still mad at him, but needs his help. She gets ticked again when she learns her dad has been checking up on her. Father and daughter are off to Pennsylvania to meet with Frank Henson. Also at the prison will be his high school sweetheart, Maggie Ingram. She stuck by Frank's side through all the accusations. Alexis has gotten to know these people. She believes in them.
Frank tells Castle what happened the night of the murder. He was welding in the garage when he set off the smoke alarm. After it went off, he heard screams from next door. He found his neighbor dead. Frank had a record, so he tried to wipe his prints from the crime scene. The victim, Kim, had a crush on him so the prosecutor painted Frank as a predator. Kim had dumped her boyfriend, Lyle Gomez, a week before she was killed. The police never looked hard at him because they already had Frank.
Castle and Alexis dig through the old case files. Charms from the victim's bracelet are seen on the floor by her body in a photo. At a coffee shop, a local cop named Lane lets Alexis know that the guy she's fighting for is guilty. After the officer leaves, Castle realizes the back door was open on a cold night when the murder occurred. Alexis knows Frank couldn't have wiped the prints off the knob because it was clean. The shop rag he used inside had grease on it from his car. Someone else was there that night. Someone else killed Kim Tolbert.
Beckett gets Lanie to run the forensic evidence of the case. Ammonium nitrate was found in Kim's system. It can be found in fertilizer. Kim's ex, Lyle Gomez, used to work in a gardening store. Castle watches as Alexis goes inside the guy's house to chat with him. Lyle says Kim asked him to pick her up that night from a party. He was caught attempting to shoplift some alcohol at a nearby shop when he heard the sirens at Kim's place. He saw Frank being arrested. He reveals his ex was seeing other guys. Maybe one of them is the killer. Too bad Frank doesn't have any fight left in him. He now wants to be strong for Maggie. He wants Alexis to let go.
Ryan finds a lead regarding Jasper Grove, the location of the party Kim attended the night she was killed. A farmhouse there was used as a meth lab possibly by kids judging by the bike tracks in the area. There were bike tracks outside Kim's house, too. Castle and Alexis meet with the victim's mother, who says her daughter was a tutor. She helped these kids in chemistry. Two science textbooks were found at the crime scene. The owner of one of them could be the killer. Castle and Alexis learn that one of the books belonged to John Henson, Frank's younger brother. He was once arrested for possession of a controlled substance.
Beckett interviews John Henson, as he lives in Manhattan. She wants to know why his chemistry book was at Kim's house. John claims he heard screams, but was in his room. He never budged even during the time the smoke alarm was sounding. Beckett thinks this is because he wasn't in his house. In Pennsylvania, Castle and Alexis relay the news to Frank, who knows his brother is the true killer. He's taking the fall because of the guilt he feels after causing a car accident that changed John and gave him memory lapses. Frank found his brother standing over the body. He's innocent, but he won't ever turn in John.
Castle believes there's a chance both brothers are innocent. They investigate bank records for all the checks that were paid to Kim for tutoring. The medical examiner's video shows that a charm from the victim's bracelet was found under her body. Actually, it wasn't from Kim's bracelet. That particular charm came from the killer. This is a big break, but the clock is ticking. Alexis knows they are running out of time. She gives her dad a hug and apologizes for being mad at him. Castle is sorry, too.
RING! A call comes in with the names of the other boys Kim tutored. Castle shows a photo of the charm that was found at the house the night she died to the local police chief. It belonged to one of his current men. It happens to be the same cop who harassed Alexis earlier-Officer Lane. The chief is the guy's father. He's the one who wrote the checks to pay for his chemistry tutoring sessions with Kim, who was going to turn Lane in as a meth dealer. This was his motive for murder. Cased closed. Frank Henson is exonerated. He's a free man. Castle lets Alexis know that what she did here was amazing.
Beckett feels like she's always going to be on the outside when it comes to Castle and Alexis. Lanie lets her know that there are no perfect families. It's up to her to start making her own new memories with them. Beckett later gets a visit at the precinct from Alexis, who is there to thank her for helping save an innocent man's life. Castle watches from afar as the two of them share a big hug. Let the new memories begin!