At a psychiatric hospital, former Chief Inspector Charles Dreyfus (Herbert Lom) is largely recovered from the murderous insanity that saw him repeatedly attempt to kill the thorn in his side, Inspector Jacques Clouseau (from the previous Pink Panther films, A Shot in the Dark, and Return of the Pink Panther). He is about to be released but Clouseau (Peter Sellers), who is now Chief Inspector and has arrived to speak on Dreyfus's behalf, comes to visit and his clumsiness and proneness to accidents drive Dreyfus insane again.
Soon thereafter, Dreyfus escapes from the asylum, intent on killing Clouseau, who apparently had become a deranged good-cop-gone-bad. His first attempt involves planting a bomb under Clouseau's apartment whilst Clouseau destructively duels with his manservant Cato (Burt Kwouk), who is under orders to keep Clouseau alert by randomly attacking him. The bomb merely destroys Clouseau's apartment whilst Clouseau himself is unharmed, largely because Clouseau has been distracted by an inflatable costume and a telephone call. Cato ends up in the hospital.
Using his knowledge of the underworld, Dreyfus frees Anthony Tournier (John Sullivan), a bank robber Clouseau had recently arrested, from prison. Other criminals with a grudge against Clouseau flock under their banner. His next step is to kidnap nuclear physicist Professor Hugo Fassbender (Richard Vernon) and the Professor's daughter Margo (Briony McRoberts), forcing the professor to build a "doomsday weapon" in return for his daughter's freedom. Because Hugo Fassbender fears to have his daughter harmed, he agrees.
Clouseau travels to England to investigate Fassbender's disappearance, with typically chaotic results, as Scotland Yard Section Director Alec Drummond (Colin Blakely) and Superintendent Quinlan (Leonard Rossiter) painfully learn. Meanwhile Dreyfus broadcasts himself to the world to announce his ultimatum: destroy Clouseau or he will destroy mankind. Disintegrating the United Nations headquarters in New York City before the disbelieving eyes of the world, he blackmails the leaders of the world, including the President of the United States (a thinly veiled impersonation of Gerald Ford, advised by a similarly poorly camouflaged Henry Kissinger), into assassinating Clouseau.
Forced to take Dreyfus's threat seriously, several nations send assassins to kill Clouseau at the Oktoberfest in Germany (whose antics include two accidentally shooting each other in bathroom stalls and one shooting another and then getting shot). Many of the nations, however, instruct their assassins to kill other assassins if necessary in order to win Dreyfus's favor and possibly get hold of the Doomsday Machine. This, combined with Clouseau's typical bumbling fashion, enables Clouseau to evade each assassination attempt just as it is about to happen, so that the assassins all kill each other instead. The assassins of 26 nations are killed in the attempt, so that the only survivors are the Egyptian (an uncredited cameo by Omar Sharif) and a Soviet Union operative. The Egyptian assassin, sneaking into Clouseau's hotel room, shoots a man he believes to be Clouseau (who is in fact Tournier, who had taken it upon himself to kill Clouseau). The Russian operative, Olga Bariosova (Lesley-Anne Down), who has sneaked into Clouseau's room, seduces the Egyptian, similarly mistaking him for Clouseau. His passionate sexuality convinces her not to assassinate him; when the real Clouseau makes an appearance, he is surprised to discover a beautiful woman in his bed who confuses him further by declaring her undying passion for him, and by finding a dead man in his bath. A tattoo on Tournier, combined with Olga's dismissively revealed knowledge, reveals to Clouseau Dreyfus's location at a castle in Bavaria, Germany.
Dreyfus is elated at Clouseau's apparent demise, but his joy is soured by a bad case of toothache. Clouseau, who has arrived in the village near Dreyfus's castle and has unsuccessfully attempted to breach the castle, thwarted every time by a drawbridge that appears to be mocking him, eventually infiltrates Dreyfus's castle hideout disguised as a dentist, intoxicates Dreyfus with nitrous oxide, and pulls one of Dreyfus's healthy teeth. Realizing the deception and laughing hysterically, Dreyfus orders Clouseau killed, but Clouseau escapes.
Enraged, Dreyfus means to seek vengeance on the world by destroying England; as he prepares for this, Clouseau, who has been thrown into the castle's barnyard, is literally catapulted onto Dreyfus's doomsday machine. Clouseau's weight redirects the disintegrator so that the beam hits Dreyfus (causing his feet to disappear) and Dreyfus's castle. As Dreyfus's henchmen, Fassbender, and his daughter, and eventually Clouseau himself escape the dissolving castle (Clouseau nearly thwarted by the drawbridge), Dreyfus himself plays "Tiptoe Through the Tulips" on the castle's pipe organ, laughing insanely and gradually disintegrating. The castle then disappears entirely, taking Dreyfus with it and destroying him once and for all (or so it seems).
Returning to Paris, Clouseau is reunited with Olga, who has dismissed Cato for the evening and intends on completing her seduction of Clouseau. This is interrupted first by Clouseau's apparent inability to remove his clothes without a struggle, and then by Cato, who chooses this time to once more follow his orders and attack Clouseau and Olga. The consequent struggle ends when all three are hurled by a reclining bed into the Seine. Immediately thereafter, a cartoon image of Clouseau emerges from the water, which has been tinted pink, and begins swimming, unaware that a gigantic version of the Pink Panther character is waiting below him with a sharp-toothed, open mouth (a reference to the film Jaws made obvious by the thematic music). The film ends when the animated Clouseau gets chased by the shark in the water (which was actually the pink panther) as the credits roll.