Lindsay (Ashley C. Williams) and Jenny (Ashlynn Yennie), two American tourists in Germany, are drugged and involuntarily detained by crazed surgeon Dr. Josef Heiter (Dieter Laser) when they seek help at his house after they get a flat tire. The women awake in a makeshift medical ward. They witness Heiter kill a kidnapped truck driver after Heiter informs him he is "not a match". Heiter secures a new male captive, Japanese tourist Katsuro (Akihiro Kitamura). The doctor explains that he is a world-renowned expert at separating Siamese twins, but dreams of making new creatures by sewing people together. He describes in detail how he will surgically connect his three victims mouth-to-anus, so that they share a single digestive system.

After Lindsay tries to escape and fails, Heiter explains that he had previously experimented with creating what he called a "three-dog", also joined mouth-to-anus. However, the three-dog died shortly after surgery. Heiter tells Lindsay that one dog tried to escape and that dog became the middle, thus this caused the most pain to the dog and as punishment for her escape attempt, she will become the middle part of his centipede. Heiter performs the surgery, placing Katsuro at the front, Lindsay in the middle and Jenny at the rear. He removes the front teeth of both women and mutilates the buttocks of both Katsuro and Lindsay in order to provide easier access to the rectums, to which he hideously stitches and grafts their mouths. During his procedure, he severs the ligaments within his victims' knees to prevent leg extension, forcing his victims to crawl. He then connects his victims together in a straight line with their mouths surgically attached to the anus of the victim in front of them.

Once the operation is complete, Heiter attempts to train his centipede as a pet, often belittling Katsuro with racist insults and beating him with a crop when he becomes rebellious. When Katsuro defecates, Lindsay is forced to swallow his excrement while the doctor watches in delight. However, he eventually becomes irritated after being kept awake by the constant screaming of Katsuro (who, as the front part of the centipede, has his mouth free and is still able to speak) and the realization that Jenny is dying from blood poisoning. When two detectives, Kranz (Andreas Leupold) and Voller (Peter Blankenstein), visit the house to investigate the disappearance of tourists, Heiter comes up with an idea to add them as replacements for Jenny in a new creation; a four-segment centipede. He offers the two detectives water spiked with sedatives in hopes of knocking the two unconscious. After being given the water, the detectives become suspicious and obtain a search warrant for his home. While the detectives leave Heiter's home, the victims attempt to escape. Katsuro attacks Heiter in the process. Their attempt to escape ultimately fails. Katsuro confesses to the doctor that he deserves his fate because he had treated his own family poorly, then commits suicide by slitting his throat with a glass shard.

Upon returning to Heiter's home, the detectives forcefully conduct separate searches as an injured Heiter hides near his swimming pool. Kranz finds the ward along with the Lindsay and the dying Jenny, and the already dead Katsuro in Heiter's bedroom. Voller begins to feel ill from the earlier drugging, and Heiter stabs him with the scalpel pulled from his leg during Katsuro's attack. Upon finding Voller dead, Kranz is shot by Heiter with Voller's sidearm. Kranz responds by shooting Heiter in the head before dying. Back in the house, Jenny and Lindsay hold hands as Jenny dies. Lindsay sobs as she is left alone in the house, trapped between her deceased fellow captives. Her fate is left unknown. The film ends with the sounds of her sobbing while the camera pans to the roof of the house.