Stephen Hillenburg, a onetime marine biology teacher who created “SpongeBob SquarePants,” an Emmy Award-winning animated Nickelodeon program about a goofy underwater world that was the defining cartoon show of its generation, died Nov. 26 at his home near Los Angeles. He was 57.

He had amyotrophic lateral sclerosis, also known as Lou Gehrig’s disease, said Susan Grode, a lawyer for the family.

Long fascinated by art and cartoons, Mr. Hillenburg turned to animation and in 1999 launched “SpongeBob” on the Nickelodeon network. The series, set underwater at Bikini Bottom, was relentlessly, even absurdly upbeat.

The title character was introduced in the show’s theme song: “Absorbent and yellow and porous is he!” Resembling an ordinary kitchen sponge wearing shorts and a necktie, SpongeBob had big eyes, two teeth and oversize pair of shoes. He lived in a pineapple under the sea at Bikini Bottom, with his pet snail, Gary, and was beamingly proud of his job making Krabbie Patties at the Krusty Krab eatery.

SpongeBob, voiced by the actor Tom Kenny, was surrounded by a zany cast of anthropomorphic creatures, including a dimwitted pink starfish named Patrick Star; a squirrel named Sandy Cheeks who adapted to underwater life by living in a dome; Squidward Tentacles, a snobbish, clarinet-playing octopus; the cranky owner of the Krusty Krab, Mr. Krabs; and the diabolical Plankton, a villain constantly plotting to steal the recipe for Krabbie Patties for his rival restaurant, the Chum Bucket.

By replaying endless variations on these characters and themes — including SpongeBob’s futile attempts to obtain a boating license from Mrs. Puff, a puffer fish — the show became a whimsical cultural phenomenon watched by tens of millions each week.

“It seems to be a refreshing breath from the pre-irony era,” Syracuse University pop-culture scholar Robert Thompson told the New York Times in 2001. “There’s no sense of the elbow-in-rib, tongue-in-cheek aesthetic that so permeates the rest of American culture. . . . I think what’s subversive about it is it’s so incredibly naive — deliberately.”

SpongeBob, in first interview, talks education

The program attracted fans among celebrities — Ellen DeGeneres, Bruce Willis and Jerry Lewis all admired its absurdist humor — and among college students, who reveled in the adult overtones that occasionally floated to the surface from Bikini Bottom.

In 2005, SpongeBob and other cartoon characters were featured in a promotional video promoting tolerance and diversity. Afterward, James Dobson, leader of the conservative activist group Focus on the Family, felt compelled to attack SpongeBob and his cartoon pals for promoting homosexuality.

“Their inclusion of the reference to ‘sexual identity’ within their ‘tolerance pledge’ is not only unnecessary,” he said, “but it crosses a moral line.”

Mr. Hillenburg replied that tolerance was certainly a theme of the show, but the idea of sexuality had no connection to the innocent characters of “SpongeBob SquarePants.”

“I consider them to be almost asexual,” he said. “We’re just trying to be funny and this has got nothing to do with the show.”

Animators and fans mourn ‘SpongeBob’ creator Stephen Hillenburg

Stephen McDannell Hillenburg was born Aug. 21, 1961, at Fort Sill, Okla., where his father was stationed with the Army. His father became a draftsman for aerospace companies and his mother was a teacher of visually handicapped students.

Mr. Hillenburg grew up mostly in Anaheim, Calif., and often went surfing and snorkeling in the Pacific. He graduated in 1984 from Humboldt State University in Arcata, Calif., where he studied marine sciences.

He taught at the Ocean Institute in Dana Point, Calif., for several years but was increasingly drawn to his childhood interest in art and storytelling. He began working on animated film projects in the 1980s and then received a master’s degree in animation from the California Institute of the Arts in 1992.

He soon began working on a Nickelodeon cartoon series, “Rocko’s Modern Life,” whose central character was a wallaby. Mr. Hillenburg later became the show’s creative director while developing the idea for “SpongeBob,” combining his interests in cartooning and marine life.

“At first I drew a few natural sponges — amorphous shapes, blobs — which was the correct thing to do biologically as a marine science teacher,” he told The Washington Post in 2001. But the character of SpongeBob — originally “SpongeBoy” until the name was changed for copyright reasons — didn’t look funny until Mr. Hillenburg reshaped him as a yellow household sponge with square pants, a white shirt and tie and an irrepressibly cheery, childlike manner.

The show premiered in 1999 on Saturday mornings, then moved to an evening time slot, where it quickly drew huge audiences. It became the No. 1 cartoon show for young viewers but often attracted at least as many adult viewers, even though Mr. Hillenburg, as executive producer, expressly forbade any references to sex, drug use, pop culture or other grown-up topics.

Perspective: ‘SpongeBob’ creator raised our spirits — and ocean awareness

“SpongeBob is really optimistic and changes the way people see things,” he told the New York Post in 1999. “He’s too naive to realize how special he is, in his odd way.”

Within three years, “SpongeBob” had more than 60 million viewers a month. It has won five Emmy Awards in various categories. “SpongeBob” animated feature films were released in 2004 and 2015, and the television show remains a popular mainstay of Nickelodeon. A musical adaptation opened on Broadway in 2017, ran 327 performances and garnered 12 Tony Award nominations.

Mr. Hillenburg’s survivors include his wife of 20 years, the former Karen Umland, and their son, Clay Hillenburg; his mother, Nancy Hillenburg; and a brother.

Even though SpongeBob worked as a hamburger cook, Mr. Hillenburg refused to license his image to sell fast food and other products he considered harmful to children. By 2009, Advertising Age magazine estimated that Nickelodeon earned $8 billion a year in sales of SpongeBob merchandise.

“How could you expect a show about a sponge to have mass appeal?” Mr. Hillenburg told the Boston Globe in 2002. “It’s just unbelievable. It’s almost like having a picture of your mother appear on everything in the world.”

Read more Washington Post obituaries

Jane Maas, trailblazing woman in advertising’s era of ‘Mad Men,’ dies at 86

Bernardo Bertolucci, Italian director of ‘Last Tango in Paris,’ dies at 77

Ricky Jay, magician whose sleight of hand defied logic or physics, dies at 72