Vending machines appear at Springfield Elementary School, and Bart quickly gets hooked on the junk food they dispense. The family is trying their very best to help him lose weight, but the junk food is still in play. Can Bart stop this addiction to sugary junk food?
The machines talk in hip-hop slang and feature strangely named snacks, some of which contain harmful ingredients such as depleted uranium. Except for Lisa, none of the kids care about the harmful snacks, and they eagerly line up to feed their money into the machines and chow down on the snacks they dispense. The vending machines' biggest customer is Bart, who becomes addicted to the junk food to the point where he won't eat any food that doesn't come from the machines, even rejecting Marge's lovingly prepared tuna steak for dinner. In just three weeks, Bart has grown obese (the effects of which are shown in a parody of the Opening Sequence), to the point that, upon arriving home, he has a heart attack and collapses on the living room.
Bart is sent to the hospital, where Dr. Hibbert explains that all the junk food he ate and the subsequent weight gain were the cause of his heart attack. Bart, however, doesn't change his eating habits, almost continuously eating the snacks until Marge puts him on a diet. When Bart can't stick to the diet, the family and some friends and neighbors stage an intervention and send Bart to Serenity Ranch, a maximum security fat camp. Also at the camp are Apu, Rainier Wolfcastle (who was last seen fattening up for a movie role), and Kent Brockman, and the camp's counselor is none other than former junk food magnate Tab Spangler (who is dealing with many anger issues). However, the family is faced with large bills for Bart's treatment. To pay for the camp, the family converts their house into a youth hostel which attracts German tourists.
Bart does not do well at the camp, and Spangler takes him home to show him what the family is going through in order to afford the treatment. Bart is horrified to see his parents and Lisa abused and humiliated by their German boarders. Spangler suggests Bart fight his addiction, and Bart takes the suggestion literally, breaking into the school and destroying the vending machines with an axe. He then steals the money from the vending machines, and goes home and announces that he's cured, as he's finally seen the true cost of his addiction. The family decides to use the money to pay for the fat camp (even though the money is ill-gotten) and give the Germans "Das Boot." Tab Spangler says that they still have three weeks of non-refundable treatment left, and Homer goes with Spangler back to the camp (whether by choice or otherwise is unknown). The episode ends with Homer and Spangler driving in Spangler's car and getting into an argument over the cheeseburger that Homer is eating.