The fatal coyote attack on a small dog at the front door of a San Francisco home has prompted a raging debate on social media and in public forums about allowing wild predators to remain in the city.

The mauling Sunday morning was the most recent in a series of coyote confrontations that have stirred up fears among Bay Area owners of cats and small dogs. As online photographs circulate of dismembered cats on people’s lawns and people report occasional dog heads being found in woods stretching from Marin County to the South Bay, some are calling for the relocation and even wholesale extermination of coyotes.

That’s not likely to happen, however. No matter how many times the horrifying death of Bella, the shih tzu snatched Sunday in front of her owners in Balboa Terrace, is repeated in San Francisco neighborhoods, coyotes are almost certainly here to stay.

It’s not just that state law forbids relocating coyotes, and that killing the animals is against coexistence policies adopted by San Francisco Animal Care and Control. Wildlife experts say that even trying to remove coyotes from San Francisco could make the problem worse.

That’s because coyote packs live under a complicated hierarchical system that allows only the alpha, or dominant, pair to breed. If the alpha male or female is killed or removed, then all the lower-ranking members can mate.

That dynamic is the basis for the old saying, “If you kill one coyote, two coyotes will come to its funeral.”

“Lethal control can lead to an increased number of females breeding at a younger age and increased pup survival, and leave a territorial void that will soon be filled by other coyotes,” said Camilla Fox, executive director of Project Coyote, a national nonprofit based in Larkspur. “It can, in a very short period, lead to a rebound of the coyote population and sometimes even an increase in the coyote population.”

Coyotes are native to California and were once plentiful in the vast sand dunes that used to cover San Francisco, according to historical and fossil records. An article in the Daily Alta California on Sept. 15, 1860, told about a coyote that sneaked into the city and ran off with a hen.

“Time was, and not long ago either, when such varmints loped fearlessly among the chaparral where now stand blocks of buildings,” the story said.

Coyotes were removed from populated areas, including San Francisco, during a nationwide extirpation program over the past 150 years. But they have since undergone an amazing recovery, tripling their historical distribution, and now inhabit an area extending from the Panama Canal to the Canadian boreal forests, said Bob Crabtree, the founder and chief scientist of the Yellowstone Ecological Research Center.

The expansion can partly be explained by the elimination of their main predator, the wolf, but Crabtree said he believes something else is at work.

“When you put a high mortality rate on any species, you are naturally selecting for the remaining individuals to know how to evade that mortality,” Crabtree said. “I have a sneaking hunch that we are unintentionally selecting for smarter coyotes that are learning to tolerate novel habitats.”

The migration into San Francisco over the past 15 years has been a remarkable story.

Sightings of the scruffy canines began in 2002 in the Presidio. Nobody knew how they got there until two years later when Golden Gate Bridge officials looked at a video that showed a coyote trotting across the bridge in the dead of night.

Coyotes have since been reported — besides in Balboa Terrace — in Stern Grove, Golden Gate Park, Glen Canyon Park, Bernal Heights, St. Francis Wood and Miraloma Park; at Lake Merced; and on Mount Davidson and the Olympic Club golf course.

Fox, who started a “Be Coyote Aware” program that teaches techniques for avoiding conflicts with the animals, said it is only natural for coyotes to repopulate territory they formerly inhabited.

“If we leave them alone, they will define their territories and protect their territories from other coyotes,” Fox said. “They will not overpopulate their territory.”

Many San Franciscans support the city’s coexistence program, even if pets occasionally get killed.

Residents in Bernal Heights have long celebrated what they consider their coyote, a healthy denizen of Bernal Heights Park that has been known to play with local dogs. A series of photographs of the coyote was recently published in Bernalwood, the community online newspaper.

“So amazing!” the caption reads. “Just remember: As much as we love the Bernal Coyote, it’s up to us to help keep her safe. Do not love her too much. Respect her space, and do not feed her.”

“Most people know they just need to be careful,” said Dan De Vries, 68, a resident of Merced Heights who has gone door to door in San Francisco preaching “Be Coyote Aware” techniques. “My impression is that people aren't all that afraid. Some think it’s kind of neat to have coyotes in the neighborhood.”

Still, some people want the newcomers gone.

“The coyotes have an unlimited food supply and no known predators. They stalk animals and stalk people,” said Carol Meschter, 65, a retired Los Altos veterinarian who believes federal trappers should be called in to remove the animals from San Francisco and other Bay Area cities. “It's a pretty dangerous situation, I think. Just because a child hasn't been killed yet doesn’t mean that it’s a safe situation.”

Coyotes are not normally aggressive to humans or dogs, Fox said, but they will protect their dens from intruders during the pup-rearing season, which lasts from April through August.

Just one fatal attack on a human has been documented in the United States. The 1981 case occurred in Glendale (Los Angeles County), when a 3-year-old girl was dragged away from her house before her father could rescue her.

Animal control officers are patrolling Aptos Avenue, where Sunday’s coyote attack occurred, and the surrounding area this week. Another dog was killed on the same street last year, and there have been several other encounters, including fatal maulings of two other dogs in the past few years.

The coyotes apparently came from nearby Stern Grove. Aggressive coyotes were also reported in the Presidio in June.

“We need to recognize that coyotes are here to stay,” Fox said. “It’s horrible when something like this happens. As the guardian of a 12-pound mutt, I feel it is my responsibility to make sure he is safe when he is outside. So when I recreate in areas where there are coyotes, I am very mindful, and I keep him on a leash.”

Peter Fimrite is a San Francisco Chronicle staff writer. Email: pfimrite@sfchronicle.com. Twitter: @pfimrite