Andy, now 17 years old, is about to leave for college, and his toys have not been played with for years. He intends to take only Woody with him, and puts Buzz Lightyear, Jessie and the other toys in a bag to be stored in the attic. Andy’s mother mistakenly takes the bag to the curb for garbage pickup. The toys escape and, believing Andy intended to throw them away, decide to climb in a donation box with Barbie bound for Sunnyside Daycare. Woody follows them and tries to explain the mistake, but they refuse to believe him.
Andy’s toys are welcomed by the other toys at Sunnyside, and are given a tour of the seemingly perfect play-setting by Lots-O’-Huggin’ Bear (simply known as Lotso), Big Baby, and Ken, with whom Barbie falls in love. They find out that that SunnySide Daycare beholds toys, from children over successive generations coming and being replaced for years. All of the toys choose to stay, except Woody, who attempts to return to Andy. Woody is found by Bonnie, one of the Sunnyside junior students. She takes Woody home and plays with him along with her other toys, which are well-treated. Meanwhile, at Sunnyside, a group of toddlers play rough with Andy’s toys.
Later, Buzz asks Lotso to have them moved to the older children’s room, but is captured. Lotso, who controls Sunnyside ruthlessly at night when the teachers and students are not around, reveals he sends new toys to distract the toddlers to keep him and his henchmen safe, not caring whether the toys are broken in the process. Seeing promise in Buzz, he resets him to his original space ranger persona, resetting his memory. At the same time, Mrs. Potato Head (who accidentally left one of her eyes at Andy’s house) sees Andy searching for the toys and convinces the toys that Woody told the truth. However, before they can leave, Andy’s toys are imprisoned by Lotso’s gang.