Scientists have observed that all solar systems start out pretty much the same. It begins in the star nursery which is called a nebulae. A nebulae is a massive collection of gas, dust and debris that is incredibly concentrated. When enough pressure builds up or there is an outside force (like an exploding star from somewhere else), the nebulae explodes and the swirling masses of ‘star stuff’ begin to clump together to form planets. So why aren’t planets in the shape of squares, or triangles?
Part of the star birth process of a nebulae includes the development of gravity. When enough gravity is created, the process of both the explosion and the clumping of the gases and dust allow the nebulae to slowly turn. This turning increases the gravity, especially the closer you get to the center of the nebular. It’s like an ice skater that is spinning. When they have their arms stretched out, the speed is slower, but as they bring their arms closer and closer towards their body, the speed increases faster and faster.
This speed continues to increase until enough pressure is built up and a star is born. A newborn star has its own gravity and the nebulae also has a gravity. It is almost like a continual fight for which gravity will win. Pieces of the gas and dust that have clumped together will crash into each other, forming bigger and bigger pieces. This continues for millions of years. As they crash into each other, they also cause each object to spin. As the size of the almost-planets increases, the spinning increases the gravitational pull and the pieces begin to fall in on themselves.
We have to remember that the forming of the planets means that they are almost all heated, many of them developing a hot core. Each time they bang into each other they create more energy which creates more heat. While this has been going on, there may also be the development of ‘gas giants’. These are usually made up of mostly gas, but they never reached the point of ‘fusion’ which is the explosion that would have allowed them to be a star/sun. So they circle around among the other planetary development, getting bigger and bigger and absorbing anything that crosses their path.
So we have a solar system that is trying to develop, containing large objects that might be planets and gas giants that will never be suns. All of these are rotating at incredible speeds. The gravity that they are creating as they rotate around moves everything that might be heavier to the center. This makes them circular or round.
As a solar system continues to become stable, planets that have already been established might cross each other’s paths and crash into each other. That can create different or even larger planets and the left over debris can create satellite moons. All of these continue to rotate and the rotation process combined with gravity makes them appear round.