At the border of the South American and nazca plate there is a long and large mountain range called the Andes why did these mountains form

The formation of the Andes mountain range is a result of the convergence of two tectonic plates: the South American plate and the Nazca plate. The Nazca plate is an oceanic plate located beneath the eastern Pacific Ocean, while the South American plate forms the continent of South America.

The Andes Mountains began to form around 65 million years ago during the late Cretaceous period. As the Nazca plate started to move eastward and subduct beneath the South American plate, a process known as subduction occurred.

During subduction, the denser Nazca plate slips beneath the South American plate, creating a boundary called a subduction zone. As the Nazca plate descends into the mantle, it heats up and generates intense pressure. This process causes the mantle to melt, leading to the formation of magma.

The magma, being less dense than the surrounding rocks, rises through cracks and weaknesses in the Earth's crust, and ultimately reaches the surface. The magma then cools and solidifies, forming igneous rocks. Over millions of years, repeated eruptions of magma and volcanic activity led to the accumulation of layers of rock, building up the Andes Mountains.

Additionally, the collision and compression between the two plates also resulted in the uplift of the crust, contributing to the height and formation of the Andes. The ongoing subduction process and associated tectonic forces continue to shape and reshape the Andes, causing earthquakes, volcanic activity, and occasional mountain-building events.