The Pinkie Pie Movie: Pony Out of Equestria is a parody of The SpongeBob Movie: Sponge Out of Water using MLP characters
A pirate named Burger-Beard travels to Equestria to obtain a magical book that makes any text written upon it come true. The book tells the story of Pinkie Pie, a pony who loves his job as a fry cook at the Sugarcube Corner restaurant and faithfully guards the secret cupcake secret formula from Trixie , business rival to Miss Cake, Pinkie's boss.
The Sugarcube Corner is attacked by Trixie. After a military battle with giant candies , Trixie feigns surrender: he uses a decoy of himself to offer the greedy Cake a fake penny, which he hides inside to gain access to Miss Cake's vault. The Trixie decoy distracts Miss Cake by crying outside the restaurant so Cake can gloat about his victory. Trixie steals the formula, leaving a fake in its place. However, just as he is about to escape, Pinkie catches him. They have a tug of war over the formula, but it magically vanishes before either can claim it.
Without the secret formula, Pinkie can't make cupcakes, and the customers become ravenous. Only Pinkie Pie believes that Trixie is innocent of stealing the formula, and when all of Equestria turns on them, Pinkie rescues Trixie with giants balloons that she and Trixie fly away in. Equestria is soon reduced to a post-apocalyptic wasteland because of the absence of Cupcakes. Pinkie Pie proposes she and Trixie team up to get the formula back; he attempts to show Trixie the meaning of teamwork, but she doesn't quite understand. Eventually, the duo decides invade Canterlot, for Trixie use a time spell, that will take them to the moment before the formula disappeared. They accidentally travel far into the future, where they meet Derpy, a magical pony whose job it is to oversee the cosmos and accidentally destroy two planets. They eventually succeed in retrieving the formula, but it turns out to be the fake Trixie had left and met themselves from the previous scene and continue.
Burger-Beard, whose seagull minions removed the final page of the book and rewritten the story so that he gets the formula, converts his ship into a food truck to sell cupcakes at a beach community named Salty Shoals. The final page, which has been discarded in the ocean, lands on the treedome of Twilight Sparkle Crazed by the lack of Cupcakes, Twilight thinks the page is a sign from the "cupcakes gods", and suggests a sacrifice be made to appease them. The town attempts to sacrifice Pinkie Pie, but she and Miss Cake smell cupcakes, and the crowd follows the scent, which leads to another world. Derpy returns because SpongeBob cost him his job as overseer of the universe. In reality, Derpy hated the job and thanks Pinkie Pie by teleporting her, Mr. Cake, Miss Cake, Twilight and Cranky Doodle Donkey to that world. Trixie joins also, stowed away in Pinkie Pie's mane. Derpy shoots them and they land on a beach.
The team locates Burger-Beard who banishes them to Pelican Island. Using the final page, Pinkie transforms himself and the others into superheroes with special powers - Fili-Second (Pinkie Pie), Mr. Superawesomeness (Mr. Cake), Sour Note (Cranky), Masked Matter-Horn (Twilight), and Miss Pinch-a-Lot (Miss Cake). They return and encounter Burger-Beard, who drives off with the formula, forcing the team to give chase. During the ensuing battle, the book gets destroyed. The team attempts to apprehend Burger-Beard, who picks the team off one by one.
Trixie, who'd been left on Pelican Island, becomes a giant alicorn heroine named The Great and Powerful Trixie and comes to assist them. After retrieving the formula, The Great and Powerfull Trixie and Fili-Second work together to create one final attack that sends Burger-Beard all the way to Bikini Atoll. Trixie, having learned the values of teamwork, returns the secret formula to Miss Cake and the gang uses the final page's magic to return to home. Equestria returns to order, and Trixie re-assumes his role as business rival, bringing things back to the "status quo".
Meanwhile, Burger-Beard, who had been left on Bikini Atoll, is stuck in the sand with his head popping out. The seagulls arrive and Burger-Beard lets them sing the Smile song. As they are about to finish, Derpy appears. He then argues with a seagull about how he doesn't like the song and the two engage in a rap battle. When the rap battle is finished, the seagulls continue to sing the song, ending the movie.
In a post-credits scene, Pinkie's pet, Gummy, think about the life.