Over time, this magma cooled and solidified, forming the first rocks. These initial rocks were likely igneous rocks, specifically ultramafic rocks, which are rich in magnesium and iron.
It's important to note that the Earth's surface has drastically changed over billions of years through processes like plate tectonics, volcanism, erosion, and weathering. This has led to the formation of a diverse range of rocks, including sedimentary and metamorphic rocks, which we see today.