Volcanoes erupt when molten rock (magma) beneath the Earth's surface rises to the surface. This can happen due to the buildup of pressure from gases dissolved in the magma, tectonic plate movements, or the presence of water in the magma. Once the pressure becomes too great, the magma is expelled through the volcano's vent or fissures, causing an eruption. This eruption can result in the release of lava, ash, gases, and volcanic bombs.