Magma composition refers to the chemical and mineralogical makeup of magma, which is molten rock beneath the Earth's surface. This composition is crucial because it determines the type of volcanic rock that will form upon solidification, influences the viscosity of the magma, and affects the style of volcanic eruptions, ranging from explosive to effusive. The elements present, particularly silica content, play a significant role in determining the behavior of a volcano during an eruption.