The Sun is the star at the center of the Solar System. The Earth and other matter (including other planets, asteroids, meteoroids, comets, and dust) orbit the Sun, which by itself accounts for about 99.86% of the Solar System's mass. The mean distance of the Sun from the Earth is approximately 149.6 million kilometers (93.0 million miles), and its light travels this distance in 8 minutes and 19 seconds. This distance varies throughout the year from a minimum of 147.1 million kilometers (91.4 million miles) on the perihelion , to a maximum of 152.1 million kilometers (94.5 million miles) on the aphelion . Energy from the Sun, in the form of sunlight, supports almost all life on Earth via photosynthesis, and drives the Earth's climate and weather. The Sun consists of hydrogen (about 74% of its mass, or 92% of its volume), helium (about 24% of mass, 7% of volume), and trace quantities of other elements, including iron, nickel, oxygen, silicon, sulfur, magnesium, carbon, neon, calcium, and chromium.
The Sun has a spectral class of G2V. G2 means that it has a surface temperature of approximately 5,780 K (5,510 °C) giving it a white color, which often appears as yellow when seen from the surface of the Earth because of atmospheric scattering. It is this scattering of light at the blue end of the spectrum that gives the surrounding sky its color.[ The Sun's spectrum contains lines of ionized and neutral metals as well as very weak hydrogen lines. The V (Roman five) in the spectral class indicates that the Sun, like most stars, is a main sequence star. This means that it generates its energy by nuclear fusion of hydrogen nuclei into helium. There are more than 100 million G2 class stars in our galaxy. Once regarded as a small and relatively insignificant star, the Sun is now known to be brighter than 85% of the stars in the galaxy, most of which are red dwarfs (information taken from wikipedia)