Life on Earth apparently evolved thanks to powerful storms that erupted on the sun more than 4 billion years ago, a new study suggests.

According to research published in Nature Geoscience, these solar eruptions warmed our home planet to such a degree that it allowed live to thrive, providing the vital energy needed to transform simple molecules into the complex building blocks of life.

Scientists have long been puzzled by the existence of early organisms on Earth—believed to have cropped up about 4 billion years ago—because by then the planet would have been an icy ball, making it too volatile for life. However, the new data suggests when our sun was younger, it was a lot more active despite being about 70 percent as bright as it is today, which in turn warmed Earth enough for life to exist.

The study analyzed data from the Kepler space telescope, which suggests newborn sun-like stars are generally very active, much like our sun would have been billions of years ago. Right now, the sun fires off about one super flare once every 100 years or so. Based on observations by Kepler of young sun-like stars, our sun may have fired off about 10 mega storms per day.

Because of these solar storms, Earth's atmospheric chemistry changed dramatically, in turn providing a spark for the early building blocks of life to evolve. For a more thorough explanation, check out the video above.