“What happens when two galaxies collide? Although it may take over a billion years, such titanic clashes are quite common. Since galaxies are mostly empty space, no internal stars are likely to themselves collide. Rather the gravitation of each galaxy will distort or destroy the other galaxy, and the galaxies may eventually merge to form a single larger galaxy. Expansive gas and dust clouds collide and trigger waves of star formation that complete even during the interaction process. Pictured above is a computer simulation of two large spiral galaxies colliding, interspersed with real still images taken by the Hubble Space Telescope. Our own Milky Way Galaxy has absorbed several smaller galaxies during its existence and is even projected to merge with the larger neighbouring Andromeda galaxy in a few billion years.” (APOD)
A interesting animation showing a simulation of two galaxies colliding, coupled with real observations of such a phenomenon happening.