Lisa calls in to an unpopular public radio station and wins tickets for four to an Albanian movie called Kosovo Autumn. Since Lisa only has four tickets, Homer leaves Maggie with Ned Flanders, who agrees to babysit free of charge. When the Simpson family returns, Marge picks up Maggie and hastily offers to pay Ned for his troubles, feeling it would be wrong not to pay him. He politely refuses, but admits that a little extra cash in his life would not hurt, seeing as the giant retail store Left-Mart is threatening his business. Marge suggests that he rent out one of his rooms to someone. He agrees, giving the room to Katja and Vicky, a pair of female students from the community college.
Taking advantage of his trusting nature, the two use their room as a staging area for a softcore pornographic website, sexyslumberparty.com. Bart and Milhouse come across a banner ad for the site while searching Ask Jeeves and share their discovery with a very amused Homer, who proceeds to spread the news around town. Marge soon discovers Homer and Bart viewing the website, and forces Homer to tell Ned everything. Upon being told, Ned angrily forces the girls to leave, but realizes that everyone has arrived to cheer for them as they leave. Horrified at both the town's mockery and Homer's betrayal, Ned promptly leaves town, moving to "Humbleton, Pennsylvania", home of the porcelain "Humble figurines", which he collects. Angered by Homer's actions, Marge and Lisa tell him to be on his best behavior for their new neighbor, Clay "Coach Clay" Roberts, who reveals himself to be a cynical bully towards Homer and litters the Simpsons' yard with Ned's fallen trees, as well as cutting their cable and siphoning gas from Homer's car.
Meanwhile, Ned finds the pseudo-Germanic town of Humbleton to be everything he ever dreamed. The townspeople are friendly to a fault; it seems to be the ultimate idyllic utopia. However, when applying for a job at the Humbleton Figurine Workshop, the manager's only request is for him to shave his moustache, declaring it "hippie-ish" and distracting. Ned briefly considers it but soon decides his "nose neighbor" is more important than the opinions of the townspeople, who immediately shun him.
Homer drives to Humbleton and pleads with Ned to return, who, upon seeing the judgmental faces of the Humbleton residents glaring at him, agrees. Unfortunately, Clay does not want to leave the house, despite Ned pointing out that Clay's $200,000 check bounced and that he legally still owns the property. Clay is eventually persuaded once Ned overpowers him by sheer force, causing him to beg for mercy before being knocked out with a chair by Homer. A few hours later, Homer obtains a pipe organ and places it in Ned's backyard for a welcome-home party, which several Springfield residents attend. Ned initially has doubts about it, believing that Homer stole it from the church; Homer says he will return it after the party. Ned is happy at the party, but it does not take long before Homer once more starts getting irritated at his old-new neighbor.