According to NASA, a solar eclipse happens when the moon's orbit aligns with Earth, and it passes between the sun and Earth.