Q: How do stars form? How was the sun made?
— Holden Taggart, Merrimac Community Charter School
A: Stars such as our sun are formed in very large dark clouds made up of primarily hydrogen and carbon monoxide molecules.
The clouds of gas — cold, dense gas — can be hundreds of light years across. Some piece of that cloud will start to become cool enough that it can’t support itself against its own gravity. It becomes gravitationally unstable, meaning it starts to collapse under its own gravity.
To form a star, it has to collapse by at least a factor of several million. As a clump of gas starts to collapse to make a star, it sometimes gets a bit of angular motion and spins, with the spinning getting faster and faster as the collapse continues.
A protostar is a star in the process of formation. It has an equatorial disk, a band of materials around the central star body, spinning very fast. This draws materials and matter inward toward the central star.
Somehow the star has figured out how to divert a lot of this matter into what is called a bipolar jet or outflow. The jet carries away the angular momentum and allows matter to ultimately fall onto this central star. This whole process of how this matter is diverted into the bipolar outflow is still not fully understood.
So planets and stars are formed together simultaneously. Every star will have a system of planets because the equatorial disk, or accretion disk, is what allows planets to condense out of it and find their orbit around the central star. It’s also why the planets are mostly in a plane, called the equatorial plane, because they’re condensed out of the equatorial accretion disk.