The universe contains billions of galaxies, of which our own Milky Way is just one. Often thought of as vast agglomerations of stars, which is how they look in photographs, galaxies actually contain other types of material as well, such as gas, dust and dark matter.
Astronomers know that galaxies began to form soon after the Big Bang, but they don't yet fully understand the process by which they ended up as we see them today. Here are some of the most promising theories of how galaxies form, how and why they merge, as well as the different varieties of galaxies that have been observed.
Theories of how galaxies form
As the universe expanded in size following the Big Bang, all the matter in it was spread out more and more thinly. At the same time there was a competing effect — the force of gravity — that was pulling this generally diffuse matter into denser clumps. Some of the clumps were just transient affairs that eventually dissipated, but in other cases the clump's gravity was strong enough to pull in more matter and allow it to grow.
As the mass of the clump increased so did its gravitational pull, causing it to collapse down to a smaller size and higher density. In this way, the first proto-galaxies were able to form within the first few hundred thousand years of the universe's existence, according to NASA's Goddard Space Flight Center.
That much is pretty much agreed by all astronomers. What is less certain is how those first proto-galaxies relate to the mature galaxies we see today. Essentially there are two competing theories, called "top-down" and "bottom-up". The top-down theory, dating from 1962, came first. According to this, the first clumps to collapse took the form of giant gas clouds which were comparable in total mass to present-day galaxies.
As the gas collapsed and its density increased, some stars formed very early on, before the gas had stabilised into a rotating disc. These early stars form the "elliptical" or bulge-like component of a galaxy, while later stars formed inside the much thinner disc component.
The bottom-up theory, also known as the "hierarchal clustering" model, is more recent and generally considered a better match with current observational evidence. It introduces two new factors that didn't play a major role in the top-down model: dark matter and galactic mergers.
We know that dark matter must exist in galaxies because of its effect on their rotation rates, and it seems likely that it played a key part in the original formation of galaxies. But the bottom-up theory, unlike the top-down theory, doesn't assume that the original proto-galaxies must have been the same size as present-day ones. Instead, it takes the view that they were much smaller, and it was only later on that they grew to their present size through repeated mergers.
Astronomers are pretty confident that mergers played some kind of role in shaping the galaxies we see today. One reason is that powerful telescopes like Hubble have revealed numerous examples of galactic mergers still occurring today.
On top of that, the most distant galaxies — which, due to the finite speed at which light travels, are seen as they were billions of years ago — look distinctly smaller and less well-structured than nearby ones, according to NASA's JWST web page. This seems a clear indication that galaxies must have evolved in the time between their original formation and today.
Different types of galaxy
Around a third of galaxies have very little gas or dust and no regions of active star formation. The largest of these, the giant ellipticals, can be up to 300,000 light-years across, while dwarf ellipticals measure only a few thousand light-years.
These are the most distinctive galaxies, consisting of a thin disc of gas, dust and stars which displays an often spectacular-looking spiral pattern. Most spiral galaxies also have a small bulge at the centre resembling an elliptical galaxy, and possibly a central bar.
This is the "everything else" category – neither a smooth, featureless ellipse nor a regular, symmetrical spiral. Irregular-looking galaxies become much more common at larger distances – in other words, earlier in the life of the universe. It's likely that, given time, they will merge into spirals or ellipticals.
Discover how telescopes are able to study galaxies through time in this video by NASA. Additionally, you can read more about the formation and evolution of galaxies at the American Museum of Natural History website.
"D. Formation of Galaxies". NASA Goddard Space Flight Center (2015).
"The Formation of the Milky Way: Two Opposing Models". Futurism (2014).
"The Assembly of Galaxies". NASA Goddard Space Flight Center (2018).
"Galaxies Over Time". NASA, James Webb Space Telescope, Goddard Space Flight Center (2022).
"Galaxies. The Building Blocks of the Universe". Hubblesite, NASA (2022).
Get the Space.com Newsletter
Breaking space news, the latest updates on rocket launches, skywatching events and more!
Andrew May holds a Ph.D. in astrophysics from Manchester University, U.K. For 30 years, he worked in the academic, government and private sectors, before becoming a science writer where he has written for Fortean Times, How It Works, All About Space, BBC Science Focus, among others. He has also written a selection of books including Cosmic Impact and Astrobiology: The Search for Life Elsewhere in the Universe, published by Icon Books.