Magma forms deep within the Earth through the process of partial melting, which occurs when heat and pressure build up at the Earth's core and cause rock to melt. Magma is red molten rock that forms below the Earth's surface and can ooze upward toward the surface. The key requirements for partial melting are an increase in temperature, decrease in pressure, and addition of volatile materials like water and carbon dioxide.