Andy was 27 and had been brought to the zoo in 1985 from Atlanta, where it had been born two years earlier.
The female bear died on Thursday at a fairly ripe age of liver failure, which zoo curator Corrine MacDonald said was a common ailment among polar bears.
Andy had an unusual appetite for fresh fruits, particularly pears, MacDonald told the San Francisco Chronicle. And although San Francisco doesn't get snow, Andy eagerly took to a blizzard of crushed ice sprayed into the polar bear enclosure by San Francisco Ice Co.
"She thrived in it," MacDonald said.
Zoo staff will be keeping a close eye on Pike, who was Andy's longtime roommate. MacDonald said polar bears tend to be solitary in the wild and had a "tolerate each other" relationship over the years.
"We're not sure if Pike recognizes she's gone," MacDonald told the Chronicle.
Texas principal bans speaking Spanish, stirs controversy
Man spent 15 hours in jail for plugging electric car into an outlet at a school