Planet Spaceball, led by President Skroob (Brooks), has wasted all of its air. Skroob schemes to steal air from the planet Druidia by kidnapping the daughter of King Roland (Dick Van Patten), Princess Vespa (Zuniga), on the day of her pre-arranged wedding to the narcoleptic Prince Valium (Jim J. Bullock). Skroob sends Dark Helmet (Moranis) to complete this task with Spaceball One, an impossibly huge ship helmed by Colonel Sandurz (George Wyner). Before they can arrive, Vespa herself abandons her marriage and flees the planet along with her Droid of Honor, Dot Matrix (voiced by Rivers), in her personal Mercedes spaceship.
King Roland contacts the mercenary Captain Lone Starr (Pullman) and his mawg (half-man, half-dog) sidekick, Barf (Candy), offering a lucrative reward to retrieve Vespa before she is captured. Lone Starr readily accepts, as he is in major debt with the space gangster Pizza the Hutt (voiced by Dom DeLuise). Lone Starr and Barf, in their Winnebago space ship (Eagle 5), reach Vespa before Spaceball One, rescue her and Dot, and escape into hyperspace. Running out of fuel, they crash on the nearby desert "Moon of Vega", and find their way to a cave occupied by the wise old Yogurt (Brooks). Yogurt introduces Lone Starr to the power of "The Schwartz". Yogurt also introduces the audience to the film's merchandising campaign, which becomes prevalent throughout the rest of the film. During their respite on the moon, Lone Starr and Vespa begin to flirt, but Vespa insists she can only be married to a prince.
Spaceball One, by breaking the fourth wall (by obtaining a VHS copy of the film and fast-forwarding to the part where the heroes crash-land), has been able to track down Lone Starr, capture Vespa, and return with her to the planet Spaceball. The Spaceballs threaten to reverse Vespa's nose job, forcing Roland to give over the code to the shield that protects Druidia. Dark Helmet takes Spaceball One to Druidia, and transforms the ship into Mega Maid, a giant robotic maid with a vacuum cleaner that begins sucking the air from the planet. Lone Starr, with Yogurt's help in repairing his ship and training in the Schwartz, races to the planet Spaceball to rescue Vespa, and then returns to Druidia, using the Schwartz to reverse the robot's sucking action and returning the air to the planet. Lone Starr and his allies enter the Mega Maid to attempt to destroy the robot. Lone Starr is forced to fight against Dark Helmet near the ship's self-destruct button, and manages to best him, causing Dark Helmet to accidentally strike the button himself. Lone Starr and his friends escape the ship, while Skroob, Dark Helmet, and Colonel Sandurz fail to reach any escape pods in time, and are left stranded aboard the robot's head as the robot explodes. They land on a nearby planet, much to the regret of its ape population.
His debt to Pizza nullified after Pizza's untimely death (he got locked in his limo and ate himself to death), Lone Starr returns Vespa to Roland and quietly leaves, taking only enough money to cover his expenses. After a disastrous lunch break at a diner (in which a musically inclined alien emerges from John Hurt), he finds a final message from Yogurt informing him that he is a prince and thus eligible to marry Vespa. Lone Starr reaches Druidia in time to stop her wedding to Valium, announcing his royal lineage, and marries Vespa himself.
- Bill Pullman as Captain Lone Starr
- John Candy as Barfolomew (Barf)
- Daphne Zuniga as Princess Vespa
- Joan Rivers as Dot Matrix (voice)
- Mel Brooks as President Skroob and Yogurt
- Rick Moranis as Lord Dark Helmet
- Dick Van Patten as King Roland
- George Wyner as Colonel Sandurz
- Leslie Bevis as Commanderette Zircon
- Michael Winslow as Radar Technician
- Lorene Yarnell as Dot Matrix (body)
- Jim J. Bullock as Prince Valium
- Dom DeLuise as Pizza the Hutt (voice)
- John Hurt as Kane
- Sal Viscuso as Radio Operator
- Ronny Graham as Minister
- Sandy Helberg as Dr. Phillip Schlotkin
- Stephen Tobolowsky as Captain of the Guard
- Dey Young as Waitress
- Rick Ducommun as Prison guard
- Tim Russ as Trooper
- Brenda Strong as Nurse
- Thomas Meehan as King Roland's aide (uncredited)