The formation of the universe began with the Big Bang approximately 12 billion years ago, resulting in the expansion of matter which was not uniformly distributed. This led to the formation of uneven clumps, eventually evolving into galaxies and then planets.