Most scientists think that the Sun and all of the planets in the Solar System formed at the same time, from a huge rotating gas cloud known as the Solar Nebula. This idea is called the Solar Nebula hypothesis. The solar nebula contained hydrogen and helium atoms from the Big Bang, tiny, dust grains, matter ejected from dead stars. The idea that the Earth was originally part of a giant gas cloud is not a new one. In 1755, Immanuel Kant suggested that the stars and planets came from a giant, whirling cloud of gas and dust.
Almost 5 billion years ago, the solar nebula began to collapse inward and to rotate more quickly. An external event, such as supernova, may have triggered this collapse. Eventually, the nebula flattened into a disk with a big lump of material in the center – the Protosun. Astronomers have found similar disks around other stars.
As the nebula contracted and gravitational energy became thermal energy, and the inner part of the nebula became very hot. Here grains of dust broke up into molecules and highly energized atomic particles.
Beyond what is now the orbit of Mars, temperatures were very low. Here frozen water, carbon dioxide, ammonia and methane probably covered dust particles.
Eventually, the contraction stopped. The Sun formed, and the region that now contains the inner planets began to cool off. This cooling caused materials with high melting points, such as iron, nickel, silicon and calcium to clump together, and the clumps began orbiting the Sun. As clumps of rock collided, they combined to form larger bodies, knows as planetesimals. Eventually, the planetesimals became the planets Mercury, Venus, Earth, Mars and the asteroids.
The outer planets, Jupiter, Saturn, Uranus and Neptune, formed at the same time as the inner planets. These planets contain large amounts of ice, which causes them to be very large but of low density.
The Earth was very hot when it first formed because of collisions from foreign bodies as well as radiation from radioactive elements within the planet. Because of this intense heat, the Earth consisted of molten rock. Heavy elements like iron and nickel sank to the center, forming the core. Gases, including hydrogen and water vapor, rose to create the first of Earth’s three atmospheres.
Eventually, solar radiation destroyed this atmosphere.
As the Earth cooled, the planet solidified. Land masses formed. Volcanic activity, as well as comet and asteroid impacts, caused a second atmosphere, containing gases like methane, nitrogen and sulfur dioxide, to form.
The nitrogen and oxygen-rich atmosphere that we know now developed when living organisms began to employ photosynthesis.