Plastic waste is piling up in ecosystems around the world, especially oceans. One of the most vexing types is Styrofoam, as well as other polystyrene foams, which are rarely accepted by recycling programs and can take centuries to break down. In the U.S. alone, an estimated 2.5 billion plastic-foam cups are discarded every year.

Like other plastic, polystyrene is dangerous to many animals that mistake it for food. But according to new research, at least one animal can safely eat this ubiquitous litter. That animal — the larvae of darkling beetles, better-known as mealworms — is now raising hopes that nature may yet give us a hand cleaning up our mess.

PHOTOS TO INSPIRE: 6 animals that recycle in their daily lives

Scientists at Stanford University have discovered that mealworms can subsist on a diet of Styrofoam and other polystyrene, which is then biodegraded by microbes in the worms' digestive systems. This is among the first detailed evidence of bacteria degrading plastic in an animal's gut, the authors say, and if we can figure out the details, it could be a game-changer for our efforts to manage plastic waste.

"Our findings have opened a new door to solve the global plastic pollution problem," says co-author Wei-Min Wu, a senior research engineer at Stanford, in a statement.

The researchers gave Styrofoam to 100 mealworms in a lab setting, where the larvae ate between 34 and 39 milligrams per day. They converted about half of that material into carbon dioxide — as they would any food source — and excreted most of the rest as tiny pellets that reportedly resemble rabbit droppings.

Mealworms that ate a steady diet of Styrofoam remained as healthy as those fed bran flakes, the study's authors report, and their droppings are even safe enough to use as soil for growing crops. Yet while all the signs are promising so far, the researchers will still keep track of the how these plastic-eating mealworms fare over time — and how they affect larger animals that eat them.

polystyrene foamThe rise of ocean plastic has led some big coastal cities, including New York, to ban polystyrene foam. (Photo: Shutterstock)

In previous research, Wu and others found that waxworms (the larvae of Indian mealmoths) also harbor gut microbes than can biodegrade polyethylene, a plastic commonly used in trash bags. But the new research seems particularly promising, given the durability and abundance of polystyrene, as well as the apparent lack of toxic byproducts from mealworms after they ingest it.

"There's a possibility of really important research coming out of bizarre places," says Craig Criddle, an engineering professor who leads a team of Stanford researchers in an ongoing collaboration with Chinese scientists to investigate the biodegradation of plastics. "Sometimes, science surprises us. This is a shock."

Now that mealworms have pulled off this feat, the researchers hope to learn what else the larvae can eat. They plan to study whether microbes in mealworms and other insects can break down plastics such as microbeads or polypropylene, a common ingredient in products ranging from textiles to car parts. By studying this process in detail, their goal is to devise more potent enzymes for breaking down plastic waste, or to produce plastics that are easier to biodegrade.

They're also looking for "a marine equivalent of the mealworm," they add, to take a bite out of the roughly 8 million tons of plastic that enter Earth's oceans every year.

It's encouraging that mealworms and other bugs might make a dent in plastic waste, but they're still no substitute for recycling, the researchers say. The U.S. produces about 33 million tons of plastic every year, only 10 percent of which is recycled. It would take a lot of larvae to eat the remaining 29.7 million tons, so as Wu tells CNN, the immediate answer to our plastic problem is to throw less away.

"We need to be better at recycling," he says. "We shouldn't waste plastic anywhere."

Russell McLendon ( @russmclendon ) writes about humans and other wildlife.