Due to a shortage of police officers, the newly-elected mayor of an unnamed American city requires the police department to accept all willing recruits, regardless of gender, body weight, skin color or age. Carey Mahoney is an easy-going man who has repeatedly gotten in legal trouble when standing up to arrogant people. Captain Reed has been lenient because he knew Mahoney’s father, a policeman. To avoid jail, Mahoney reluctantly joins the police force, planning to be thrown out as a loophole. The chief of police, Henry Hurst, outraged by the Mayor’s plan, wants the new cadets to be forced to quit rather than being thrown out.
Lieutenant Thaddeus Harris, an ambitious instructor, makes their lives miserable to force them to quit. Commandant Eric Lassard, the only dissenter to Harris and Hurst’s schemes, wants to give the new cadets a chance. Harris appoints two cadets, Copeland and Blankes, as squad leaders to help him.
Mahoney schemes to fail. Lassard reveals to Mahoney his deal with Capt. Reed to keep him at the police academy for the next 24 weeks. Eventually he has a change of heart, having fallen in love with cadet Karen Thompson. Mahoney becomes friends with fellow cadets Larvell Jones, a human beatbox arrested with Mahoney; George Martin, a ladies man; Eugene Tackleberry, a gun-obsessed security guard; Leslie Barbara, an overweight cowardly man; and Moses Hightower, a gentle giant. He and Harris build up a mutual enmity when Mahoney pranks the lieutenant in retaliation for his harsh measures.
At Lt. Harris’ request, Blankes and Copeland investigate a weekend party organized by Mahoney. Mahoney tricks Blankes and Copeland into attending a party at a gay bar called the Blue Oyster, where they are intimidated into dancing, with the real party taking place somewhere else. Seeking revenge, Blankes and Copeland plant a prostitute in Mahoney’s dormitory, to be conveniently found during mandatory room checks. While smuggling her off the campus, Mahoney is forced to hide with her under a podium as Commandant Lassard leads in a group of senior officers to give a lecture. While Mahoney is not looking, the prostitute performs fellatio on Lassard, who struggles to keep a straight face. As the room is cleared, Mahoney steps out from under the podium but finds Lassard still present, leading Lassard to assume Mahoney was under the podium alone. Despite attempting to report this to Harris, Lassard eventually relents.
Hightower reveals to Mahoney that he has not driven a car since he was 12. To help Hightower prepare for a critical driving test, Hightower and Mahoney steal Copeland’s car. The police chase them, and Hightower greatly sharpens his driving skills while escaping. Immediately after Hightower passes the driving test, Copeland racially insults fellow cadet Laverne Hooks for an accident. Hightower, quietly angered by the insult, overturns Copeland’s police car, despite Harris’ demands and Hooks’ pleas for him to stop. Harris promptly ejects Hightower from the academy, upsetting the other cadets.
Mahoney admits his frustration to Barbara but refuses to quit. Blankes and Copeland fail to trick Mahoney into fighting them. Upset with their misconduct, Barbara stands up for Mahoney and shocks everyone by knocking out Copeland with a lunch tray. Blankes retaliates, and Mahoney inadvertently becomes involved in a brawl. When Lt. Harris asks who started the fight, Mahoney takes the blame to protect Barbara, allowing Harris to expel his most despised cadet.
Before Mahoney leaves, a riot breaks out downtown, accidentally caused by Douglas Fackler, a clumsy cadet. Mahoney helps the cadets pacify the crowd. The cadets are accidentally transported to the epicenter of the rioting. During the general confusion, one criminal steals Blankes and Copeland’s cadet revolvers; they seek refuge in the nearest building, only to discover it is the Blue Oyster Bar. Barbara runs past Harris and a gang surrounds him, with their group leader taking Harris as a hostage; Mahoney attempts a rescue but is taken as a second hostage. Just as both are about to be killed, Hightower appears, bluffs the madman, and knocks him unconscious. Hooks arrests him.
Mahoney and Hightower are both reinstated and graduate. For their rescue of Harris and capture of his kidnapper, they receive the academy’s highest commendation and medals. Each address the crowd, but as Mahoney attempts to give a long speech, Lassard uses the same prostitute to prank Mahoney. All of the cadets (minus Blankes and Copeland) graduate, finally winning a respectful salute from the reluctant Harris.