Small celestial bodies, like comets or dwarf planets, can sometimes have bizarre shapes — just look at ‘Oumuamua, the interstellar visitor whose strange, elongated form sparked endless theories as it passed through our solar system. So, what’s stopping large moons, planets, or even stars from coming in not only all sizes, but all shapes? It all comes down to gravity.
No matter how irregularly shaped an object is, its self-gravity pulls equally in all directions. But when an object becomes massive enough that its gravity can overcome the internal forces between atoms that bond its irregular features in place, protrusions will want to fall toward the center of the body, creating a sphere. So, as a body collects more mass, it smooths out any edges, preventing any cube- or pyramid-shaped planets.
But not every planet or moon is perfectly round. This has to do with their rotation, which causes the material around the equator to want to spin off, like mud from a tire. But gravity is too strong, so the body just gains some extra width around its middle, called an equatorial bulge. In our solar system, slowly rotating Mercury and Venus are nearly perfect spheres, while Jupiter and Saturn bulge out near their equators. Even Earth isn’t a perfect sphere. Our world is about 0.3 percent thicker in the middle. Stars also bulge out near their equators for this reason.