There are more than one hundred billion stars in our milky way, and the sun is the most powerful star situated in the middle of the solar system. It is called as the yellow dwarf. Yellow because of the color and dwarf, because it is small for a star, but it can fit almost one million earth and is roughly 109 times the diameter of the earth. It is surrounded by smaller stars, planets, the moon, comets, etc. It is also referred to as the hot ball of fire. Sunlight is very much essential for all living beings. It is the biggest source of heat and energy and without sunlight, there will be no light, no day and no life at all.
Even though it is a star, how come it looks big while the other stars look like twinkling dots to us? That is because it is closer to the earth while the other stars are far off. It has a surface temperature of 10,000 degrees Fahrenheit, and it produces 380 billion megawatts of power and energy.
It was formed 4.57 billion years ago when a part of a giant molecular cloud consisting of hydrogen and helium collapsed, which is referred to as solar nebula. Most of the collapsing nebula got grouped towards the center to form the proto-star that eventually became the sun, and the rest flattened up into an orbiting disk to form the planets and the other solar system bodies.
It was Aristarchus who first said that the sun was in the center of the solar system and before that it was assumed that the earth was in the middle of the solar system.
FORMATION IN DETAIL:
Space might look empty, but it contains lots of gasses and dust. Mainly it contains gasses like hydrogen, helium and other elements like oxygen, carbon, neon, iron, etc. which are the remaining portions of the dying stars. There are waves of energy in the space that compresses the solar nebula to come closer, and there is a gravitational force happening in the space which tries to collapse them. Because of this gravitational force, the material that is coming closer begins to spin.
Due to the spin, it gets flattened up into a disk-like shape and in the center, the mass that was pressed together forms the proto-star. Thus the sun was born. The hydrogen atoms in the young protostar fuse together to form helium and in that process releases photons which are responsible for the sun to shine and produce energy.
The young proto-star is just a ball of hydrogen in the beginning, and it took nearly fifty billion years for it to get heated up as the temperature and pressure increased due to the nuclear fusion of hydrogen atoms to form helium, and this was happening inside the sun at 18 million degree Fahrenheit.
Every second, close to four million tons of matter are converted into energy and solar radiation. This is the half of a stage called main sequence stage and in this stage; the sun is referred to as a main sequence star. It would spend approximately ten billion years as a main sequence star and approximately after several million years; it will exit this stage to become a red giant.
Around 5.4 billion years from now, once the hydrogen and helium inside the sun get consumed completely, the sun will balloon up into a red giant and researchers say that it might engulf our earth and other planets which will result in the death of our planet.
Because of the red giant's powerfulness, the earth will get desiccated into a hotter place and will no longer be capable of fitting in lives and the sun can no longer be hot to burn the oxygen and the carbon-di-oxide. Slowly the sun will lose its power and will become a white dwarf.