At a poker night held at Lenny's house, Homer wins the pot without even realizing it, causing a frustrated Moe to yell at him. When Lenny defends Homer, saying that its not his fault he's "slow", which angers Homer. When he tells his family, they reluctantly agree with Lenny, and Marge suggests that he takes an adult learn course down at the community centre to improve himself. Homer looks in on the various classes, hosted by Lenny (tobacco spitting) and Moe (dance self defence), and notices the respect the students give to the teachers, and decides to become a teacher himself. He talks to the administrator and accepts an opening to teach a class on having a successful marriage. Brimming with confidence, Homer proudly goes around talking about his new job, but once in front of a class, he realizes that he has no idea how to teach. The class collectively gets up to leave, but when Homer mentions his conversation with Marge in bed, the class decides to stay, eager to hear gossip. Marge soon discovers that everyone in town knows her personal secrets, reacting by confronting Homer about it and he promises to stop. He instead continues telling her secrets anyway. Homer then takes the night off teaching class by having his class observe the family over dinner.
When Moe lets it slip that Homer has been telling their secrets again, Marge is furious, and throws out both the group and Homer. When Homer tries to get back in, Marge stops him, saying she can long longer trust him, and refuses to let him back in. Homeless, Homer stays in Bart's tree house. Marge tries to reassure Bart and Lisa that she and Homer love the children, despite their current situation, but Lisa and Bart are worried their parents will get divorced. Marge tries to get advice from Reverend Lovejoy, who tells her to get a divorce. Despite only a few days passing, Homer quickly descends into filthy misery, his clothes becoming ragged and dirty, and slowly starving.
While Homer longs for his wife, Moe comes by the Simpsons' house to declare his interest in Marge, who turns him down. When Homer comes into the house with flowers he picked for Marge, Moe claims Marge came on to him, then jumps out the window. Dejected, Homer leaves, but when one of his dirty rags is caught on a table, he realizes he does have one thing to offer Marge. Homer professes his total and utter dependency on Marge, and she tells him that that is not a good thing, but Homer then makes his winning argument: he loves her, he needs her to love him, and can not afford to ever lose her trust again or he will end up dead. Marge is won over and allows Homer to return to the house. The family is glad that he has returned, although Moe is less than thrilled.