Scientists have captured two supernovae at the moment of explosion. They've used the Kepler Space Telescope to find stars that have exploded in a brilliant display.

For the past three years, the researchers have kept an eye on 50 trillion stars, hoping to watch as supersonic shockwaves reached their surfaces after explosions deep in the core. Now for the first time ever, researchers have watched a "shock breakout" in an exploding supergiant star.

Stars that are 10 to 20 times the mass of our own sun can puff up to become supergiants before they eventually become supernovae. These stars are large enough that Earth's orbit easily fits inside them. When these stars run out of fuel, their core collapses into a neutron star and a supersonic shockwave then blows up the entire star. When this wave reaches the surface of the star, it causes a bright flash of light known as a "shock breakout."

In this latest study, the researchers examined two massive red supergiants with the help of Kepler. One of them, known as KSN 2011a, is nearly 300 times the size of our sun. The second, called KSN 2011d, is about 500 times the size of our sun. Both of them are Type II supernovae and were created when their interiors ran out of fuel.

Fortunately for the researchers, they were able to see the moment that these stars ran out of fuel. The result was a massive flash from a shock breakout.

"The flash from a breakout should last about an hour, so you have to be very lucky or continuously stare at millions of stars just to catch one flash," said Peter Garnavich, one of the researchers.

In this case, the researchers focused on the stars in order to catch them in action. These latest findings could help scientists better understand similar explosions. This, in turn, may help them learn more about how chemical complexity and life was scattered in space over time in the Milky Way galaxy. This is important for those who examine how our Milky Way Galaxy was first formed.

The findings are published in the March 2016 issue of the journal The Astrophysical Journal.