Remy, a young anthropomorphic rat with heightened senses of taste and smell, dreams of becoming a chef like his human idol, the late Auguste Gusteau. Conversely, the rest of his colony, including his older brother Émile and their father, Django, the clan leader, only eat for sustenance and are wary of humans. The rats live in an elderly woman's attic outside Paris, but when the woman discovers them, Remy becomes separated from the others during their hasty evacuation. Encouraged by an imaginary Gusteau, he explores until he finds himself on the roof of Gusteau's namesake restaurant.
Remy sees the restaurant's new garbage boy, Alfredo Linguini, struggling to fix a leek soup he ruined. Remy sneaks in and improves the soup; Linguini notices and traps Remy while keeping his presence secret from Skinner, Gusteau's former sous-chef and the restaurant's new owner and head chef. Skinner confronts Linguini about the soup, but it is served by accident and unexpectedly becomes a hit. Colette Tatou, the restaurant's only female chef, persuades Skinner to keep Linguini and support Gusteau's motto, "Anyone can cook." Skinner demands Linguini replicate the soup but spots Remy, ordering Linguini to take him outside and kill him. Alone, Linguini realizes Remy understands him and persuades Remy to assist with cooking.
Remy discovers that he can control Linguini's movements like a marionette by pulling on his hair while hiding under his toque. They recreate the soup and continue cooking at the restaurant. Colette begrudgingly trains Linguini but steadily appreciates him heeding her advice. Later, Remy reunites with his clan. After Remy tells Django that he intends to stay at the restaurant, Django shows him a group of exterminated rats to convince him that humans are dangerous, but Remy defies his warnings and leaves.
Meanwhile, Skinner is shocked and enraged to discover through a letter from Linguini's late mother that Gusteau is Linguini's father, making him the rightful owner of the restaurant. After Skinner's lawyer verifies that Linguini is Gusteau's son, Skinner hides the evidence in an envelope; Remy steals the envelope and brings it to Linguini. Skinner is fired and Linguini is promoted to head chef. The restaurant thrives as Remy's recipes become popular, and Linguini develops a romantic relationship with Colette. Food critic Anton Ego, who negatively reviewed the restaurant shortly before Gusteau's death, announces to Linguini that he will review the restaurant again the following day. After Linguini takes credit for Remy's cooking at a press conference, he and Remy have a falling out. As revenge, Remy leads his clan on a raid of the restaurant's pantries. Linguini arrives to apologize, but upon discovering the raid, he furiously expels Remy and his clan from the restaurant.