A new study has found that drinking two or three cups of coffee a day can extend a person’s lifespan.

The study, which was presented at the American College of Cardiology’s 71st Annual Scientific Session, found the caffeinated beverage lowers the risk of heart disease and prevents dangerous heart rhythms, which can decrease the chances of early death.

What’s more is it doesn’t matter if the caffeine user is drinking ground coffee or instant. Both produced the same results, researchers found.