Nature can offer no more wonderful sight than a starry night sky! The black velvet studded with thousands of diamond-like twinkling stars has evoked awe and wonder since ages. One wonders what stars might be made of? What are these great balls of fire like Sun made of ? The answer to this question is they are made of hydrogen and helium gas mostly! These gases are in fact the most abundant elements in the universe, though they are comparatively scarce, here on earth. Helium was in fact discovered through the optical spectrum of the Sun. This element was detected in the Sun even before it was discovered on Earth.
It would be more correct to call a star a ball of plasma (which is an ionized gas), principally made up of hydrogen and helium. To understand what is the energy source of the stars, one must know what nuclear fusion is. Stars are natural fusion reactors that derive their energy from hydrogen fusing into helium, and later fusion to other heavier elements.
Do not confuse the fusion of hydrogen with its combustion. Hydrogen combustion is an endothermic chemical reaction that creates heat, but hydrogen fusion creates far more energy as it involves the fusion of its nuclei into helium nuclei. To understand what makes stars, we must first understand their life cycle. The sequence that we need to understand is: ignition of gigantic fusion reactors, birth of a star, and how the star dies? All these questions are closely connected with this subject. The life cycle of a star is called stellar evolution and its composition changes as it evolves through stages.
The star's life is a constant tussle between enormous forces. One is the gravitational force that tries to compress the star and other is the thermal pressure in opposition to it. Let us understand in depth, how a star is born and how it evolves.
Stage 1: Protostellar Formation
Our galaxy has enormous clouds of cold atomic and molecular hydrogen, which are at a temperature of few degrees above absolute zero. Every piece of matter in this universe is attracted to another piece by gravitational force. The cold clouds start compressing under the gravitational force, and as they get compressed, they get heated up. This happens as the gravitational potential energy is changed to kinetic energy. As these enormous clouds start compressing into small dense gaseous pockets, small gaseous spheres of protostars (yet to be stars) get created. At this stage, stars are primarily made of hydrogen, trace amounts of helium, and fractional amounts of other heavier elements.
Stage 2: Main Sequence
These protostellar gaseous blobs go on compressing and heating up. Over this whole compression process, temperature of the gas rises from a few degrees above absolute zero, to about 7 million Kelvins. As the hydrogen gas heats up to become a hot plasma, at 7 million Kelvins, hydrogen nuclei start fusing together to form helium nuclei in the protostellar core. The difference in their masses is converted to energy. This is the source of energy of stars. Stellar fusion creates thermal pressure that heats up the core and exactly balances the gravitational crunching force. The star reaches hydrostatic equilibrium and steadily starts fusing hydrogen into helium. This stage is called the main sequence stage. Our Sun is in the main sequence now, burning hydrogen into helium in the core. In this stage, stars are still mostly made up of hydrogen, but there is a steady increasing supply of helium in the core now. How long a star stays in the main sequence depends on its mass! In fact, whole life of a star depends on its initial mass. The more massive the star, more is the temperature of the stellar core. Subsequently, higher the temperature of the stellar core, faster is fusion rate of hydrogen fuel. So in short, the more massive a star, the shorter is its life span on the main sequence, which is the hydrogen fusion phase. Our Sun is an average-sized, dwarf star, with average mass. So it has a long lifespan on the main sequence, which will last for 4.5 billion years. The main sequence is the longest and most stable phase in the life of a star.
Stage 3: Post Main Sequence Stellar Evolution
It may so happen that one day, the hydrogen fuel in the core will get exhausted, which will signify the end of main sequence. As fusion in stellar core stops, the thermal pressure can no longer stop the gravitational crunch and the stellar core gets compressed under it, heating up again. The temperature goes on increasing till it reaches the point where helium starts fusing into Carbon. Heavier the nuclei, higher is the fusion temperature required. In stellar astronomy jargon, this phase that lasts till the helium fusion begins is called the Red Giant phase of the star. During the red giant phase, the external envelope of the star expands and the star becomes a giant! The post main sequence evolution is complicated, as the helium fusion is extremely sensitive to temperature and there is a large turbulent instability in the core. At this stage, hydrogen, helium and carbon make most of the stellar stuff. More massive the star, more number of elements it creates through fusion. Low mass stars will only form helium and then the core pressure will be sustained by electron degeneracy pressure. The outer envelope is ejected and the core remains as a white dwarf, which is a very dense and compact object, forming a planetary nebula. If the star is even more massive, it will fuse helium into carbon, and carbon into even heavier elements. If the star is phenomenally massive, this fusion process continues up till creation of Iron by fusion. Stars are made up of all elements ranging from hydrogen to Iron at this stage. However, Iron cannot be fused to form other heavier elements through fusion. So at this stage, the core implodes and a spectacular event called the supernova occurs. It is one of the biggest explosive processes in the universe. The core becomes a spinning neutron star called a pulsar and the outer envelope blasts out. During this Supernova, other heavier elements, heavier than Iron are formed through neutron capture.
As you can see, synthesis of heavy elements like carbon and nitrogen happens in the belly of a star. These heavier elements are what we are made of. So whatever we are made of, was synthesized in the fiery belly of a star and the spectacular explosion like a supernova. So, as you can see, we are all made of stardust, literally! Without stars, heavier elements like Carbon that are the basis of life, would never have been created.