The next night, An, Sussy, and Dex set off safety sparklers in New Pretty Town that spell out “The Smoke Lives.” Just as Tally predicted, the Specials set off toward the disturbance from their headquarters in hovercars. She and David bungee jump onto the roof, where David jams the hovercar exit with special glue. Tally pries open the elevator door and they bungee jump down the shaft.
In the basement, Tally and David find a room labeled “Long Term Detention.” Before they can hide, Dr. Cable exits the room. Tally surprises her and David knocks her out. But Dr. Cable is with someone: Shay, who has been turned pretty.
Tally is devastated to witness the brain damage the operation has wrought on her best friend. Shay is untroubled and upbeat, completely and utterly changed. She lives in New Pretty Town now, but has been brought in by Dr. Cable to talk to the caged Smokies. David goes to break them out, and Tally and Shay stay behind. A carefree Shay assures Tally that she forgives her, but Tally knows it is only the lesions talking. While David and Tally help the prisoners out of their cages, Shay buys time by telling the Specials trying to contact Dr. Cable through her tablet that she's busy. David and Tally manage to gather everyone, but Az is conspicuously missing. Maddy tells him that he can’t help his father; Az is dead.
The escapees steal Dr. Cable’s tablet and take the elevator to the roof, where Tally has called the hoverboards. The group separates into two people per board. They will meet later at a cave near the ruins. Tally and Shay are on one board, David and Maddy on another, two other escapees on a third, and Croy alone on the fourth.
As she and Shay coast out of the city, Tally asks her friend what changed her rebellious spirit into acquiescence. Though Shay contends that it was just because she realized it was time for her to grow up, Tally sows doubt by suggesting to Shay that the shift in her thinking happened at the same time as her operation. Shay asks Tally if she is in love with David. Maybe, Tally says, she doesn’t know. She apologizes for accidentally betraying the Smoke, and Shay’s immediate forgiveness brings her to tears; Shay is no longer Shay, her forgiveness isn’t real.
Newly arrived at the ruins, Tally finds that Maddy has managed to break into Dr. Cable’s tablet, revealing a wealth of information documenting how pretties become Specials.
The group makes a new home in the Rusty Ruins. Since the message in the sky, more uglies have ventured out into the wasteland, hoping to make contact with people from the Smoke. Tally does her part in helping to convince them of the truth of the operation—that their brains will be altered. Over time, Shay has become subdued. Tally thinks she might like being the only pretty among them.
Soon, Maddy announces that she has found a cure for the lesions, but Shay will not consent to take it. She maintains that being ugly is what makes people determined to rebel against authorities; they aren’t happy with themselves, and unhappiness breeds dissent. Tally wants to give her the pills anyway, but Maddy refuses. Az died because the Specials tried out an experimental memory removal treatment on him during his surgery, and she will not make an unwitting test subject out of Shay.
Instead, Tally volunteers to be the test subject. She will give herself up to Dr. Cable, undergo the operation, and in a few weeks the members of the new Smoke can come and rescue her and she will take the pills. David protests, but Tally does not budge. From Maddy’s willingness to go along with the plan, it becomes clear Maddy knows the truth of what Tally did. The time has come to confess to David.
David, shocked by Tally’s admission, storms out and does not return to the Smoke all night. Tally is stopped from pursuing him by Maddy, who believes that further exposure to David will change Tally’s mind. Tally realizes that while David may not blame her for Az’s death, Maddy does. The night before she goes, Tally writes a letter to herself, written permission for Maddy to administer the pills.
Shay wants to accompany Tally back to the city. She is tired of hiding out. Tally gives in. They hoverboard back to the city and set out on foot together, waiting to be found. A hovercar lands in front of them, and Tally gives herself up.
Watching the sparklers light up a message of revolution over the buildings of New Pretty Town, David reaches an important conclusion. While he was sad at first to hear Tally tell the would-be runaway uglies of the night before that the Smoke didn’t exist in any physical location right now, he can see that the Smoke’s existence isn’t only physical. It exists in the minds of all those who would rebel against tyranny. The government can force people under the knife as much as they want, but there will still be uglies resisting. As long as there is civilization, there will be dissent.
The idea is a comfort to Tally, as they break into Special Circumstances and liberate their loved ones. But when she finds Shay transformed, Tally is devastated anew. The easy forgiveness Shay offers is only further indication that the old Shay is gone, replaced by society’s mass-produced beauty ideal. Shay refers to Tally’s betrayal as her “ugly little secret,” a turn of phrase which underlines one of the book’s central messages: beauty isn’t defined by the way a person looks.
Tally asks Shay what she remembers of life before the operation, why she isn’t upset with Tally for her treachery. Shay’s response—that her dissenting beliefs were an indication of her immaturity—is particularly poignant. Tally is faced with the reality of what she has done.
Only a couple months ago, it was Tally who conflated being pretty with being mature and Shay who valued individuality as a sign of maturity. Now, the tables have turned, and Tally can see what her ignorance has cost her friend. It seems suddenly ridiculous to believe that a single operation could make a person mature. Tally can’t decide which is worse—Shay hating her or Shay not hating her.
When Shay refuses the cure for the lesions, Tally feels a deep sense of responsibility, and decides to turn herself in to the pretties and get the operation, so that she can subsequently become a test subject for the cure. The reader understands that she has volunteered to be a test subject as a form of repentance for her grievous misdeeds. Because of her, people have died and a whole way of life has been destroyed. This small gesture, much like Az and Maddy fleeing the city, or Tally tossing her locket into the fire, could help to bring about great change.