If the sun was calm when you were born, you might look forward to a longer life than someone born in a period of high solar activity.

The sun's cycles last about 11 years, typically including three years of "solar maximum"—when activity like solar flares, sunspots, and solar storms are at their peak—and eight years of "solar minimum." In a new study in the Proceedings of the Royal Society B, researchers looked at demographic data of Norwegians born between 1676 and 1878, and found that the lifespans of those born during "solar maximum" periods were, on average, 5.2 years shorter than the lifespans of people born during "solar minimum" periods, phys.org reports.

"Solar activity at birth decreased the probability of survival to adulthood," thus causing the decrease in average lifespan, the researchers say. A high percentage of the deaths of those born during "solar maximums" occurred by age 2.

The authors think ultraviolet radiation is behind the effect. Solar activity is linked to higher levels of UV radiation, which is known to have an impact on survival and reproduction; the authors say there's a possibility that's because it causes cell and DNA damage.

There's also evidence suggesting UV radiation degrades vitamin B9, or folic acid—and a shortage of that vitamin before birth has been linked to higher illness and death rates.

Interestingly, the study also found that being born during "solar maximum" significantly reduced fertility for women and decreased the number of children they had who survived to adulthood—but only if those women were born into a poor population, suggesting that more well-to-do women may have been better able to avoid the sun or mitigate the sun's harmful effects through a healthier diet.

A good rule of thumb? "If you are pregnant, don't get a tan," says one co-author, according to LiveScience. (Another recent study finds that if you feel younger than your age, you'll likely live longer.)

This article originally appeared on Newser: Sun's Activity During Birth Could Affect Your Death

More From Newser