Morocco's earliest history belongs to the Berbers, or Amazigh peoples, who have inhabited North Africa for thousands of years. Long before recorded dynasties, these communities developed languages, agriculture, and trade networks across the mountains, plains, and desert fringes.
By the first millennium BCE, Phoenician and later Carthaginian traders established coastal trading posts. The region eventually came within the orbit of the powerful Mediterranean civilizations, setting the stage for Roman involvement and the blending of local and foreign cultures.
From the 1st century CE, much of northern Morocco became part of the Roman province of Mauretania Tingitana. The Romans built cities, roads, and farms, and the ruins of Volubilis near Meknes remain the most impressive testament to this era, with mosaics, arches, and a basilica still visible today.
Roman control gradually weakened, and after the empire's decline the region passed through periods of Vandal and Byzantine influence on the coast while Berber polities reasserted themselves inland. This transitional period preceded the transformative arrival of Islam.
Arab armies brought Islam to North Africa in the 7th and 8th centuries, and the new faith spread among the Berber populations over the following generations. In 788 Idris I, a descendant of the Prophet Muhammad, founded the Idrisid dynasty, widely regarded as Morocco's first Islamic state.
His son Idris II developed Fez into a major city and intellectual center. The Idrisids established a model of sharifian rule, linking political power to descent from the Prophet, a pattern that would recur throughout Moroccan history.
From the 11th to 13th centuries, two great Berber dynasties built vast empires spanning Morocco and Islamic Spain. The Almoravids founded Marrakesh and ruled from roughly 1040 to 1147, followed by the Almohads, who reigned from about 1121 to 1269 and created monuments such as the Koutoubia and the Hassan Tower.
These empires represented the height of medieval Moroccan power, uniting North Africa with al-Andalus and fostering remarkable achievements in architecture, scholarship, and trade before fragmenting under internal and external pressures.
The Marinids ruled from the 13th to 15th centuries, making Fez a center of learning and building its famous madrasas. They were followed briefly by the Wattasids, and then by the Saadians, who in the 16th century repelled Portuguese and Ottoman threats and won the Battle of the Three Kings in 1578.
In the 1660s the Alaouite dynasty rose to reunify Morocco, and they continue to reign today. Throughout these centuries Morocco preserved a distinct identity and largely resisted the full colonial conquest that befell many neighboring lands.
In 1912 Morocco was forced to accept a French protectorate, with Spain administering northern and southern zones and Tangier under international status. The colonial period spurred a strong nationalist movement that rallied around Sultan Mohammed V.
Morocco regained its independence in 1956, and the sultanate became a kingdom the following year. Under Mohammed V, Hassan II, and now Mohammed VI, the country has modernized while maintaining the continuity of the Alaouite monarchy, which remains central to national life.
| Period | Era |
|---|---|
| Roman Mauretania Tingitana | 1st-3rd century CE |
| Idrisid dynasty | 788-974 |
| Almoravid dynasty | circa 1040-1147 |
| Almohad dynasty | circa 1121-1269 |
| Marinid dynasty | 1244-1465 |
| Saadian dynasty | 1549-1659 |
| Alaouite dynasty | 1660s-present |
| French protectorate | 1912-1956 |
Timeline of major periods in Moroccan history
Morocco's first Islamic dynasty was the Idrisids, founded by Idris I in 788. His son Idris II expanded Fez into an important city and center of learning.
Morocco regained its independence in 1956, ending the French protectorate that had begun in 1912. The sultanate became a kingdom the following year under Mohammed V.
The Alaouite dynasty rules Morocco today, having governed since the 1660s. The current monarch is King Mohammed VI, who took the throne in 1999.
Loved this? Useful? React below โ your feedback helps other readers.