The health benefits of coffee are fairly well-known: The caffeinated bitter drink can aid in losing weight, curing headaches, and preventing diabetes. But it turns out that coffee can also act as an antioxidant, according to a new study out of Monash University in Melbourne, Australia.

Researchers had previously been aware of the antioxidant properties of coffee, some even arguing that coffee provides a better source of antioxidants than even fruits or vegetables, which are known to have particularly high levels of them. Antioxidants are chemicals that fight free radicals — elements found naturally in the body or in environmental toxins that damage cells and may play a part in causing cancer. But the new study, published in PLOS ONE, wanted to examine more deeply how antioxidants and free radicals flow in every stage of the coffee brewing process — from bean to steamy cup of java.

“Our research studied both the Arabica coffee bean itself and what happens to its stable free radical and antioxidant properties during the brewing process,” said Dr. Gordon Troup, a physicist at Monash University and author of the study.

The Melbourne researchers teamed up with chemists from Illycaffè, an Italian coffee roasting company that has been associated with coffee research. The chief chemist of Illycaffè, Luciano Navarini, had asked Troup to collaborate on antioxidant research in 2012. They used EPR (electron paramagnetic resonance) spectroscopy to achieve their results.

“Troup was one of the first scientists to discover free radicals in coffee in 1988, and so it made sense for Illycaffè … to collaborate with Dr. Troupe and his team on this significant piece of research into free radical and antioxidant behavior in coffee,” Navarini said.

The researchers watched the behavior of both free radicals and antioxidants throughout the coffee brewing process — and found that under particular conditions, coffee acts as an antioxidant, stabilizing free radicals.

“The most important aim of this research was to better understand the development of stable free radicals during the roasting process and the possible influence exerted by developed radicals on the well-documented coffee antioxidant properties,” Navarini said. “We also wanted to evidence possible coffee constituents as a source of antioxidant activity.”

The antioxidants in coffee have been shown to potentially fight obesity and aid in losing weight. Past researchers discovered that they may actually help in protecting retinas and eyes. And coffee’s mind-stimulating effects may contribute to preventing Alzheimer’s disease, other forms of dementia, or chronic diseases like cancer and stroke, according to various other studies. However, researchers are still trying to figure out whether antioxidants are always good for you — and what the best food source of them is. One study published in 2013 found that having more antioxidants in your diet doesn’t always mean better health and, oftentimes, people who get their antioxidants from fruits, vegetables, and wine instead of coffee or other foods might be better off.

At any rate, enjoy your coffee — its benefits typically outweigh its adverse effects — and as long as you drink in moderation, you can rest assured it’s going to be helping you in some way.

Source: Troup G, Navarini L, Liverani F, Drew S. Stable Radical Content and Anti-Radical Activity of Roasted Arabica Coffee: From In-Tact Bean To Coffee Brew. PLOS ONE. 2015.