Magma and lava are terms which are usually used interchangeably. The one major difference which separates one from the other has to do with location, location, location.
Simply put magma is molten rock underneath the ground whereas lava is molten rock which has flowed out of the Earth’s crust onto the Earth’s surface.
Molten rock, also known as melt, is formed due to the very hot temperatures inside of the Earth. Temperatures of lava flows can range from 1202-2012 °F (650-1100°C). In the upper mantle, which is approximately 1800 mi (2890 km) below the Earth’s surface, the temperatures can be just as hot, yet the rock tends to remain in a solid state. This is due to the immense pressures at this depth. At such high pressures the atoms are so tightly compressed that the atoms of the rock are unable to break free from their mineral structure.
Thus only under certain circumstances is magma able to form. One such circumstance is when there is a decrease in pressure (decompression). Decompression loosens the bonds holding the atoms together and allows the rock to melt. Another way to form magma is when volatiles are added into the mix. Volatiles are elements or molecules such as water (H20) or carbon dioxide (CO2) which have low boiling points. Water has a boiling point of 212°F (100°C) and carbon dioxide has a boiling point of -70°F (-57 °C). When volatiles are present in the rock, the rock will melt at lower temperatures (or at higher pressures) than they normally would. A third way for magma to form is from the transfer of heat when the red-hot magma rises towards the Earth’s surface. As the magma rises it comes into contact with surrounding cooler rocks. In some cases the magma is hot enough to melt the surrounding rocks producing more magma.
The type of lava and the way in which it flows onto the Earth’s surface depends greatly on the composition and the viscosity of the lava. Viscosity is defined as the resistance to flow and affects the speed at which lava will flow. Water, for example, is much less viscous than molasses which means that water is able to flow much more quickly and easily. Lava with a high viscosity tends to flow slowly and clog. This can entrap gases, increase pressure and lead to highly explosive eruptions. The devastating eruptions at Mount Tambora in 1818 and Krakatoa in 1883 (the top two deadliest volcanic eruptions with a combined death toll of 128 000 people) contained highly viscous lava.
Lava with low viscosity tends to flow easily. It forms puddles and rivers of molten rock as it flows over the surface. These lava flows are much calmer and much less explosive than those of high viscosity.