Eli5: How are planets formed?



I understand that planets are essentially space rock that got together and made what we know today as planets, I’m simplifying this a lot but let’s go with it. What I want to know is how those space rocks are formed and then put together to make planets? Where did the rock come from? Is it elements clashing together millions of times over until they form what we know today as space rocks?

In: Physics

Planets form in a region of space with the right sort of raw material. As that material collects, due to gravity, forming a star, the remaining material which has enough velocity collects in orbit around the star. After that’s it’s bumping into each other until everything is synchronized into a plane, then a ring, then a ball due to self gravity.

Our star system is a second-generation one. That means that whatever is in it used to be part of other stars before that. When those previous stars blew up, they formed interstellar clouds of matter. Some part of such a cloud happened to condense into our solar system. And yes, small pieces of stuff lumped together randomly until they formed asteroids, and then planets.

The atoms from an exploding supernova create the debris for a planet to form atoms heavier than iron require a supernova without one all you get are gas giants.