The Museum of Ice Cream is generating heaping scoopfuls of money but has also encountered a rocky road full of activists, politicians and copycats.

Though its exhibits may be more high-calorie than high-culture, the museum became an impossible ticket after garnering social-media endorsements from such celebrities as Kim Kardashian West and Beyoncé.

But the seemingly vanilla institution has also been labeled a danger to the environment, caused headaches for local bureaucrats and even become party to litigation threats.

At a time when venerable cultural institutions across the U.S. struggle with admission revenue, the Museum of Ice Cream keeps melting hearts. Part art installation, part ice-cream emporium, and a picture-perfect backdrop for selfies, it’s made for Instagram. Millennials are eating it up. Opening in New York in July 2016, the museum has since brought its giant animal cookies mounted on carousels, its gardens of gummies and its maze of rooms to Los Angeles, Miami Beach and San Francisco.

Tickets often sell out within just a few minutes of going on sale for $38 apiece. In San Francisco, where the museum will operate in a historic bank built in 1910 through September, tickets go for as much as $125 on the secondary market. More than 250,000 people attended the Miami Beach run, and in San Francisco attendance has averaged roughly 1,700 a day, which suggests revenue from gate receipts alone would be in the $20 million range in two years of operation. That’s not counting the inevitable gift shop, which sells, among other things, pieces made by museum co-founder Maryellis Bunn.

“Ice cream is something that is universal, and really does bring people together,” Bunn, 26, told MarketWatch. “Everyone has an anecdote about ice cream.”

The museum, on the other hand, has generated nearly as many headaches as anecdotes.

Environmental activists and city officials say the massive pool of plastic sprinkles — the museum’s signature attraction — have ended up spilling into city streets and could threaten wildlife.

Spread through the neighborhood by visitors after they exit, this sprinkle scourge has spurred months of investigations by city officials in California, according to hundreds of pages of documents that MarketWatch obtained in public records requests.

“Please help!” San Francisco Supervisor Aaron Peskin wrote to the city’s Department of Public Works after learning about the problem from a constituent.

“I hope it’s been made clear San Francisco’s standard of cleanliness,” one official wrote after several weeks of talks with the museum over the sprinkles escaping from the small swimming pool-size enclosure.

Officials in San Francisco have been investigating the sprinkles issue — including generating pages-long memos exhaustively documenting efforts — since last year and have hit the museum with several citations.

“The little pieces of plastic concern me because of the biolife,” said Eva Holman of the San Francisco chapter of the Surfrider Foundation. “Birds and fish could consume them, and about a third of seafood consumed by humans has microplastic particles in it,” she said. “There’s nothing in place in the storm drains to capture anything this small.”

In Los Angeles, the ordeal stretched more than six months, as merchants discovered the sprinkles in the vicinity surrounding the old warehouse it occupied. Eventually it got bad enough they complained to Miguel Vargas, executive director of the Arts District Business Improvement District, he said in an email to museum co-founder Manish Vora, 38, and Los Angeles Councilmember Jose Huizar.

“[M]any Arts District business owners and residents have been noticing sprinkles in their shops, in the gutters, in tree wells and all over the neighborhood,” Vargas wrote in an email message obtained via a public-records request. “I’ve personally seen the sprinkles outside of City Hall and on the sidewalks in Little Tokyo.”

After Miami Beach issued several thousand dollars’ worth of fines, the museum took action, and may have found a solution: It moved the sprinkles pool farther from the exit of the one-time hotel it operated within, paid staff to patrol the vicinity for errant sprinkles, and implemented a system in which sprinkles are blown off patrons. Miami Beach staffers added mesh coverings to several nearby storm drains.

City spokeswoman Veronica Paysse said that Miami Beach’s mayor, Dan Gelber, was “pleased with the progress.” A spokeswoman for the museum operators told MarketWatch that “all fines were reversed.”

Bunn said that the company behind the ice-cream museum, 1 and 8 Inc., stopped producing the sprinkles earlier this year and is currently trying to figure out an alternative, perhaps including a biodegradable version. She said efforts have been made to keep sprinkles off the streets.

“We were definitely not expecting this,” she said.

Meanwhile, Bunn said that just about every day her team hears about or discovers a knockoff museum somewhere in the world. “There have been places that have literally copied, back to back, the entire exhibition,” Bunn said.

Imitators have become such a problem for 1 and 8 that it has obtained trademarks to the museum’s concept and is seeking a U.S. patent for the entire museum. Bunn said she has sent cease-and-desist letters on multiple occasions.

It was inevitable that others would try and copy the idea, Bunn conceded, as the “experience industry” is going to be worth billions in the future, she predicted. “We’re not only creating a new business, but it’s really a billion-dollar industry — it’s an entirely new industry.”

And her plans extend still further: “I want to build a city,” Bunn said.

Let’s hope the streets are paved with something other than sprinkles.