John Waters had no idea. He didn’t understand the power of the greatest television series of all time until kids started recognizing him in public. Twenty years ago, before his cult classic Hairspray was turned into a Broadway smash, The Pope of Trash was largely known for making movies from which parents shielded their children’s eyes. That began to change soon after February 16, 1997, the night Waters appeared on The Simpsons.

"Little children came up to me in airports and said, ‘You were on The Simpsons,’" Waters told me recently. "You know, it was an audience I never had." The grade schoolers may not have heard of Pink Flamingos or Polyester, but they were starstruck by the guy with the pencil mustache who was cool enough to be on their favorite show. Waters felt honored.

"When I was younger, I always wanted to be a Disney villain," he said. "And this was about as close to that as I got. Finally I was a cartoon character — and I kind of look like one anyway. So I was happy."

It’s a wonder that it took so long for The Simpsons to enlist Waters. His transgressive strain of humor could be seen in a program that in its early days was shocking enough to draw the ire of the sitting president. When Waters aficionados Bill Oakley and Josh Weinstein became Simpsons showrunners in the mid-’90s, they cast the comedy icon. In "Homer’s Phobia," Waters plays a Simpsonized version of himself: He’s a gay man named John who owns a kitschy antique store.

Today, such a cameo wouldn’t be terribly significant. But this was the late ’90s. Ellen DeGeneres was still two months away from coming out on her eponymous sitcom. An animated series showcasing a gay character was especially novel. "Bill and I wanted to do stuff that no one had done," Weinstein said. But they also wanted to do it in a way, he added, that "was real and not silly sitcom phoniness."

That meant developing a story absent the kind of sanctimony that you’d find in an after-school special. John spends the episode not only helping Homer at least start to shed his homophobia but also acquainting the Simpsons family — and the adolescent-filled audience — with gay culture. In the era of "don’t ask, don’t tell," nearly two decades prior to the Supreme Court ruling in favor of same-sex marriage, the second part was just as radical as the first.

"The idea was that this character was introducing gay life to a happy home that knew nothing about it," Waters said.

Not everyone saw the value in the concept. In fact, a censor initially decreed that the script for "Homer’s Phobia" was unfit to produce. If The Simpsons’ creative staff didn’t go out on a limb for the episode, it might not have seen the light of day.

The history of LGBT characters on network television goes back nearly half a century. In 1971, on the fifth episode of the first season of CBS’s All in the Family, America’s favorite bigot Archie Bunker has a mini-existential crisis after learning that his burly, ex-athlete drinking buddy is gay. The short-lived ABC sitcom The Corner Bar debuted a year later and featured Vincent Schiavelli as a set designer who’s gay. And by the late ’70s, Billy Crystal was starring on ABC’s Soap as Jodie Dallas, a gay man who directs TV commercials.

More and more programs soon began tackling homosexuality, usually one short arc at a time. But out of a frustrating fear of offending both viewers and sponsors, networks tended to approach the subject gingerly. When two gay characters were shown together in bed on the drama Thirtysomething in 1989, ABC reportedly lost $1.5 million in ad sales. The men made no physical contact during the scene, yet the network received hundreds of complaints. In 1990, Harvey Fierstein guest starred on The Simpsons as Homer’s stylish assistant. While hinted at, the character’s sexuality was never mentioned.

Five years after that, ABC felt the need to move the start time of a Roseanne episode centered on a gay wedding from its 8 p.m. slot to 9:30 p.m. An ABC spokeswoman claimed that the shift was due to the episode’s "adult humor" and "not the idea of the gay wedding." In 1996, Friends celebrated a lesbian couple’s nuptials — but left out the ceremonial kiss. As Stephen Tropiano, author of The Prime Time Closet: A History of Gays and Lesbians on TV, put it: "You were very, very limited about what you could show."

After years of cracking jokes at the expense of Mr. Burns’s closeted and sycophantic assistant Waylon Smithers, the staff of The Simpsons made a point not to be coy about John’s sexuality. "It was understood that he’s gay," Weinstein said. "We didn’t want to deal with a lot of innuendo."

"Homer’s Phobia" tied together a pair of incomplete story threads. The first, pitched by writer George Meyer, was called "Bart the Homo" and focused on other characters questioning Bart’s sexuality. The second, thought up by Oakley and Weinstein, was titled "Lisa and Camp" and traced Lisa’s discovery of campy things, like the work of Ed Wood and John Waters.

The two ideas formed the basis of the script assigned to Ron Hauge, who’d just come to The Simpsons after writing for a handful of TV series, including Seinfeld. (His credits include the classic episode "The Marine Biologist.") To get Waters’s voice down, Hauge read the filmmaker’s memoir, Crackpot. And when thinking about how to create a foil for Waters, he recalled über Simpsons writer John Swartzwelder giving him this advice: "Write Homer the way that you would write a dog. He’s got really [a] limited attention span. He loves his food. He loves his sex. He’s completely stupid. And he will defend his family to the death." In other words, Homer as homophobic ignoramus wouldn’t be a stretch.

"We had a big task in this episode, and that was to overcome Homer’s prejudice," Hauge said. "You have to do it with a good, positive character who can earn that." We meet this character in the first act, after Bart causes $900 worth of damage to the Simpson house. To pay the repair bill, Marge resorts to selling her grandma’s "Civil War doll." The problem, the proprietor of the collectible shop Cockamamie’s tells her, is that the century-plus-old Confederate soldier figurine is actually just a circa-1970s liquor bottle. Marge’s disappointment doesn’t spoil the fun for the family, which geeks out over the quirky items lining the shelves. (For inspiration, episode director Mike B. Anderson said, the animators looked at photographs of the Pasadena City College Flea Market.) Among other expensive vintage tchotchkes, there’s a robot from Forbidden Planet–like sci-fi flick "Clank, Clank You’re Dead!," a TV Guide owned by Jackie O., and an homage-paying plastic pink flamingo.

The enthusiasm Waters’s character has for all of this stuff bewilders Homer, who can’t fathom the interest in chic junk. "It’s camp!" says John, who’s wearing an old bowling shirt of Homer’s that he found at Goodwill. "The tragically ludicrous? The ludicrously tragic?" Still, Homer invites John over. After arriving, he quickly falls in love with the Simpsons and their campy decor. "I’ve got the exact same curtains, only in my bathroom," he tells Marge when he spots the kitchen window’s corn-cob-dotted drapes. John and Homer even dance to Alicia Bridges’s disco classic "I Love the Nightlife," a song that had just been given a second life on the soundtrack of The Adventures of Priscilla, Queen of the Desert. The scene is slyly subversive. After all, back then a sitcom audience didn’t often see suburbia through the eyes of a gay man.

Homer in particular is charmed, until Marge explains to her dense husband that John is gay. Homer then screams as his reflexive disgust sets in. The problem isn’t that John is gay, he reasons, it’s that he’s a sneak. "I like my beer cold, my TV loud, and my homosexuals fuh-laming," he huffs before refusing to join his family for a day out with John, who brings the Simpsons into his world by taking them on a sordid celebrity tour of Springfield.

Homer’s anger only intensifies when Bart — uninfluenced by his dad’s retrograde attitude — begins to embrace John’s campy sensibilities. Bart dances in a wig to "The Shoop Shoop Song (It’s in His Kiss)," chooses a pink Sno Ball over a chocolate cupcake, and dons a Hawaiian shirt. "There’s only two kind of guys who wear those shirts: gay guys and big, fat party animals," says Homer. "And Bart doesn’t look like a big, fat party animal to me." When John asks Homer what he’s got against gay people, the best he can come up with is that they aren’t "usual" and that "they ruined all our best names like Bruce, and Lance, and Julian."

At that point in Hauge’s original script, John was supposed to turn to Marge and say, "You know who would like him? My dad." Waters objected, only because in real life he and his father were on good terms. "Dad" was changed to "landlord," but the line eventually was cut. Waters loved the story, especially a late scene suggested by writer Steve Tompkins. In an attempt to literally set Bart straight, Homer takes Bart to a steel mill. What he doesn’t realize is that it’s a gay steel mill. When one of the strapping workers says, "We work hard, we play hard," a disco ball descends from the ceiling and all the employees get down to C+C Music Factory’s "Gonna Make You Sweat (Everybody Dance Now)." When Simpsons staffers watched the sequence for the first time, Anderson said that they didn’t just laugh — they stomped their feet.

"To see that was really, really funny," said Waters, whose hometown of Baltimore once was home to a thriving steel mill, "because steelworkers are usually not stereotyped as gay."

As a last resort, Homer tries to make his son a real man by taking him deer hunting with Moe and Barney. No prize bucks materialize, but while driving home, Moe suggests stopping at Santa’s Village, where Bart can shoot a captive reindeer. He refuses to pull the trigger, and, naturally, the herd attacks Homer.

He’s saved only when Marge and Lisa arrive with John, whose missile-shooting Japanese robot Santa Claus toy scares off the animals. When Barney expresses disappointment that the group was "saved by a sissy," Homer sticks up for John. "We owe this guy, and I don’t want you calling him a sissy," he says. "This guy’s a fruit, and a … no, wait, wait, wait: queer. Queer. Queer. That’s what you like to be called, right?" "That," the hero replies, "or John."

It was a fitting response. "There’s such a thing in humor called ‘The Comedy of Yes,’" Hauge said. "The basic idea is that in any unusual or difficult situation, somebody acting surprisingly positive can be as fun as making them snarky."

Homer’s thank you seems genuine if pathetic. "This is about as tolerant as dad gets, so you should be flattered," Lisa says. Realizing that Homer has a long way to go toward enlightenment, John doesn’t let him off the hook. "Well, Homer, I won your respect, and all I had to do was save your life," John says. "Now, if every gay man could just do the same, you’d be set." The subtle dig was the perfect way to cap the episode.

"I’ve always said the only way to change anyone’s opinion is to make him laugh first," Waters said. "It still is."

Typically, when the staff of The Simpsons submitted a script for approval, the censor responded with just a few notes. "It was always very mundane," Oakley said. Things like: "Please substitute for Homer’s use of the word ‘ass.’" But on "Homer’s Phobia," the showrunners were sent back three pages containing dozens of notes that Oakley said concerned "every single thing in the episode that had to do with being gay or the word ‘gay.’" The document, he added, ended with this: "The entire subject and content of this episode is unacceptable for air."

Oakley and Weinstein were infuriated. They could fight small changes, but this was different. "They didn’t want anything to do with it from A to Z," Oakley said. Instead of tabling the idea, the showrunners ignored the censor and pushed ahead on production. (Oakley said that unlike most celebrity guests, Waters kindly stretched out his voice-recording session to a whole day, which gave the team more editing flexibility. "I felt like I was doing The Fred Waring Show," Waters said.) It was a risky move; each episode took nearly a year to make. "Over the next 10 months," Oakley said, "we just kept our fingers crossed."

Then they caught a break. In September 1996, Fox president John Matoian stepped down. Oakley and Weinstein assume the network brought on a new censor, because when the pair submitted the animation for "Homer’s Phobia," the only comment they got back was: "acceptable for broadcast."

The gamble paid off. "It’s one of the top episodes we ever did," Oakley said. "Homer’s Phobia" won an Emmy for Outstanding Animated Program and a GLAAD Media Award for Outstanding TV–Individual Episode. Director Mike B. Anderson also took home an Annie Award for Best Individual Achievement: Directing in a TV Production. Waters and Anderson even worked together on Uncle John, a new series starring the cartoon version of Waters. Anderson said that MTV was interested in the concept, but didn’t end up buying it. Sadly, no one did. "We never actually got paid," Waters said. Anderson still has a three-minute sample animated clip that he made to show networks. He once asked his collaborator about putting it online, but Waters replied, "The internet is the booby prize, isn’t it?"

Meanwhile, the TV universe was inching toward progress. In April 1997, Ellen came out on Ellen. But during the next season of the sitcom, ABC began airing a parental advisory warning before every episode. In spring 1998, after reportedly asking DeGeneres to focus less on gay issues, ABC cancelled Ellen. That fall, Will & Grace premiered on NBC. The series, about the friendship between a gay man and a straight woman, was a hit. And two years later, the season finale of Dawson’s Creek featured prime-time’s first romantic, sustained kiss between two gay men.

Over the next decade and a half, the number of gay, lesbian, bisexual, and, more recently, transgender TV characters multiplied. (On The Simpsons, both Marge’s sister Patty and Mr. Smithers have come out of the closet.) Their inclusion no longer requires disclaimers or very special episodes.



"It’s improved where they’re gay and it makes no difference to the plot," Waters said. "They’re not the wisecracking best friend of the woman now. You can have gay villains. I think that’s progress."

To much of America, Waters himself has transformed from a dangerous provocateur into a kooky uncle. Two of his movies — Hairspray and 1990’s Cry-Baby — have been turned into Broadway musicals. Now 70, he writes books, tours the country, does voice-over work, and still acts in movies. Staying true to his camp roots, he even made a recent cameo in Alvin and the Chipmunks: The Road Chip.

In a way, his career has had a similar trajectory to the show on which he appeared 20 years ago. Both began by shocking the prude establishment. Now they’re both beloved American institutions. The Simpsons hasn’t invited Waters on again, but if it does he’ll be ready.

"I want to come back and turn straight," he said. "That would freak ’em out."