There’s no more refreshing way to get a caffeine kick on a sweltering day than by sipping an iced coffee. And now that so many coffee drinkers have made the summer switch from their usual steaming Starbucks to an ice-cold beverage, we wondered: Does cold coffee supply the same healthy nutrients as the hot kind?

The short answer: Yes. Adding ice to coffee probably doesn't change the bioactive compounds that give hot coffee its healthy rep, says Frank Hu, MD, PhD, professor of epidemiology and nutrition chair at the Harvard T.H. Chan School of Public Health.

“There are a wide range of health benefits associated with coffee drinking,” says Dr. Hu, who has studied coffee extensively. “Many major studies have shown that drinking coffee on a regular basis is associated with a decreased risk of developing type 2 diabetes, heart disease, neurodegenerative disease, and dying prematurely. It’s also associated with improved cognitive function and decreased risk of depression.”

The exact mechanism by which coffee can work these wonders is not known, but researchers believe it’s tied to coffee’s high levels of antioxidants, polyphenols, and minerals, says Dr. Hu.

But while coffee has the same nutritional profile no matter what the temperature is, one specific type of cold coffee—cold brew—has a health advantage over a cup of hot coffee that's simply been poured over ice cubes or stored in the fridge.

Cold brew, which is made by steeping coffee grounds in cold water for typically an entire day, is less acidic than regular coffee. This means it can be easier on the digestive system, particularly for people who struggle with heartburn or a sensitive stomach, explains Joan Salge Blake, RD, clinical associate professor at Boston University and author of Nutrition & You.

Because cold brew is less acidic, many people find it tastier—and there's less of a need to mask the acidic taste by loading it up with cream, milk, and sugar, turning it into a major calorie bomb, says Dr. Hu. This is something you might find yourself doing with more acidic iced coffee.

Another nutritional benefit to consider: The caffeine concentration in your joe. Cold brew can have a higher caffeine concentration than regular ice coffee or hot coffee, since it tends to be brewed as a concentrate with a steeper ratio of coffee to water (though adding water or milk later would even this out a bit). If you’re sensitive to caffeine, a cold brew could leave you more jittery, says Dr. Hu, or mess with your sleep if you drink it later in the day.

Also, people tend to buy iced drinks in larger containers than the do hot ones, says Dr. Blake, and they guzzle them faster. That means caffeine's effect could hit you faster and harder if you drink your java cold.

Yet if you can handle it, more caffeine isn’t necessarily bad, says Dr. Hu, and in fact it actually delivers health benefits independent of coffee's antioxidants and other nutrients. “Some of the benefits of coffee seem to be linked to the caffeine content, like the positive effects on cognitive function and the decreased risk for neurodegenerative diseases like Parkinson’s,” he says.

Bottom line: coffee has major health perks whether you like it hot, iced, or cold brewed. Drink up!

This story originally appeared on Health.com.