From 711 to 718, as part of the expansion of the Umayyad Caliphate, nearly all of the Iberian Peninsula was conquered by Muslim armies from across the Strait of Gibraltar, resulting in the collapse of the Visigothic Kingdom. Only a small area in the mountainous north of the peninsula stood out of the territory seized during the initial invasion. The Kingdom of Asturias-León consolidated upon this pocket of territory. Other Christian kingdoms such as Navarre and Aragon in the mountainous north eventually surged upon the consolidation of counties of the Carolingian Marca Hispanica. For several centuries, the fluctuating frontier between the Muslim and Christian controlled areas of the peninsula was along the Ebro and Douro valleys.
Under Islamic law, Christians and Jews were given the subordinate status of dhimmi. This status permitted Christians and Jews to practice their religions as People of the Book but they were required to pay a special tax and had legal and social rights inferior to those of Muslims.
Conversion to Islam proceeded at an increasing pace. The muladÃes (Muslims of ethnic Iberian origin) are believed to have formed the majority of the population of Al-Andalus by the end of the 10th century.
The Muslim society was itself diverse and beset by social tensions. The North-African Berber peoples, who had provided the bulk of the invading armies, clashed with the Arab leadership from the Middle East. Over time, large Moorish populations became established, especially in the Guadalquivir River valley, the coastal plain of Valencia, the Ebro River valley and (towards the end of this period) in the mountainous region of Granada.
A series of Viking incursions raided the coasts of the Iberian Peninsula in the 9th and 10th centuries.
Córdoba, the capital of the caliphate since Abd-ar-Rahman III, was the largest, richest and most sophisticated city in western Europe. Mediterranean trade and cultural exchange flourished. Muslims imported a rich intellectual tradition from the Middle East and North Africa. Some important philosophers at the time were Averroes, Ibn Arabi and Maimonides. The Romanised cultures of the Iberian Peninsula interacted with Muslim and Jewish cultures in complex ways, giving the region a distinctive culture. Outside the cities, where the vast majority lived, the land ownership system from Roman times remained largely intact as Muslim leaders rarely dispossessed landowners and the introduction of new crops and techniques led to an expansion of agriculture introducing new produces which originally came from Asia or the former territories of the Roman Empire.
In the 11th century, the Caliphate of Córdoba collapsed, fracturing into a series of petty kingdoms (Taifas), often subject to the payment of a form of protection money (Parias) to the Northern Christian kingdoms, which otherwise undertook a southward territorial expansion. The capture of the strategic city of Toledo in 1085 marked a significant shift in the balance of power in favour of the Christian kingdoms. The arrival from North Africa of the Islamic ruling sects of the Almoravids and the Almohads achieved temporary unity upon the Muslim-ruled territory, with a stricter, less tolerant application of Islam, and partially reversed some Christian territorial gains.
The Kingdom of León was the strongest Christian kingdom for centuries. In 1188 the first modern parliamentary session in Europe was held in León (Cortes of León). The Kingdom of Castile, formed from Leonese territory, was its successor as strongest kingdom. The kings and the nobility fought for power and influence in this period. The example of the Roman emperors influenced the political objective of the Crown, while the nobles benefited from feudalism.
Muslim strongholds in the Guadalquivir Valley such as Córdoba (1236) and Seville (1248) fell to Castile in the 13th century. The County of Barcelona and the Kingdom of Aragon entered in a dynastic union and gained territory and power in the Mediterranean. In 1229 Majorca was conquered, so was Valencia in 1238. In the 13th and 14th centuries, the North-African Marinids established some enclaves around the Strait of Gibraltar.
From the mid 13th century, literature and philosophy started to flourish again in the Christian peninsular kingdoms, based on Roman and Gothic traditions. An important philosopher from this time is Ramon Llull. Abraham Cresques was a prominent Jewish cartographer. Roman law and its institutions were the model for the legislators. The king Alfonso X of Castile focused on strengthening this Roman and Gothic past, and also on linking the Iberian Christian kingdoms with the rest of medieval European Christendom. Alfonso worked for being elected emperor of the Holy Roman Empire and published the Siete Partidas code. The Toledo School of Translators is the name that commonly describes the group of scholars who worked together in the city of Toledo during the 12th and 13th centuries, to translate many of the philosophical and scientific works from Classical Arabic, Ancient Greek, and Ancient Hebrew.
The 13th century also witnessed the Crown of Aragon, centred in Spain’s north east, expand its reach across islands in the Mediterranean, to Sicily and Naples. Around this time the universities of Palencia (1212/1263) and Salamanca (1218/1254) were established. The Black Death of 1348 and 1349 devastated Spain.
The Catalans and Aragonese offered themselves to the Byzantine Emperor Andronicus II Palaeologus to fight the Turks. Having conquered these, they turned their arms against the Byzantines, who treacherously slew their leaders; but for this treachery, the Spaniards, under Bernard of Rocafort and Berenguer of Entenca, exacted the terrible penalty celebrated in history as “The Catalan Vengeance” and seized the Frankish Duchy of Athens (1311). The royal line of Aragon became extinct with Martin the Humane, and the Compromise of Caspe gave the Crown to the House of Trastámara, already reigning in Castile.
As in the rest of Europe during the Late Middle Ages, antisemitism greatly increased during the 14th century in the Christian kingdoms. (A key event in that regard was the Black Death, as Jews were accused of poisoning the waters.) There were mass killings in Aragon in the mid-14th century, and 12,000 Jews were killed in Toledo. In 1391, Christian mobs went from town to town throughout Castile and Aragon, killing an estimated 50,000 Jews. Women and children were sold as slaves to Muslims, and many synagogues were converted into churches. According to Hasdai Crescas, about 70 Jewish communities were destroyed.
This period saw a contrast in landowning characteristics between the western and north-western territories in Andalusia, where the nobility and the religious orders succeeded into the creation of large latifundia entitled to them, whereas in the Kingdom of Granada (eastern Andalusia), a Crown-auspiciated distribution of the land to medium and small farmers took place.
Upon the conclusion of the Granada War, the Nasrid Sultanate of Granada (the remaining Muslim-ruled polity in the Iberian Peninsula after 1246) capitulated in 1492 to the military strength of the Catholic Monarchs, and it was integrated from then on in the Crown of Castile.