Researchers looked at data from more than 447,000 people and found those who drank one to three cups a day had about a 10 percent lower risk than those who don't drink coffee at all. And those who drank four or more cups a day had a 20 percent lower risk.

Study authors say it's the caffeine that's at play here. Some evidence suggests caffeine might act as a sort of sunscreen by protecting DNA from damage when it comes in contact with UV rays.

In 2012, researchers found caffeine might lower the risk of developing the most common form of skin cancer, basal cell carcinoma.

The authors of that study also mentioned previous research suggesting caffeine could block the formation of skin tumors. But at that time, researchers did not believe caffeinated coffee intake affected melanoma. (Video via ABC)

Researchers say although coffee might lower your risk of skin cancer, the best way to avoid the disease is to avoid ultraviolet radiation.