The Solar System consists of the Sun and the bodies that orbit it (most prominently Earth), being a system of masses bound together by gravity. The name comes from Sōl, the Latin name for the Sun. It formed about 4.6 billion years ago when a dense region of a molecular cloud collapsed, creating the Sun and a protoplanetary disc from which the orbiting bodies assembled. The fusion of hydrogen into helium inside the Sun's core releases energy, which is primarily emitted through its outer photosphere. This creates a decreasing temperature gradient across the system. Over 99.86% of the Solar System's mass is located within the Sun.
The most massive objects that orbit the Sun are the eight planets. Closest to the Sun in order of increasing distance are the four terrestrial planets – Mercury, Venus, Earth and Mars. These are the planets of the inner Solar System. Earth and Mars are the only planets in the Solar System which orbit within the Sun's habitable zone, where liquid water can exist on the surface. Beyond the frost line at about five astronomical units (AU), are two gas giants – Jupiter and Saturn – and two ice giants – Uranus and Neptune. These are the planets of the outer Solar System. Jupiter and Saturn possess nearly 90% of the non-stellar mass of the Solar System.