788: Idris I, a descendant of the Prophet Muhammad, founds the Idrisid dynasty, often regarded as the first Moroccan state.
11th–13th centuries: The Berber Almoravid and Almohad dynasties build empires spanning the Maghreb and Muslim Spain, with Marrakech as their capital.
1666: The Alaouite dynasty, which still reigns today, consolidates control over Morocco under Moulay Rashid.
1912: The Treaty of Fez makes most of Morocco a French protectorate, while Spain controls a northern zone and the far south.
1956: Morocco regains independence from France and soon recovers most of the Spanish protectorate, with Mohammed V as sovereign.
1975: King Hassan II organizes the Green March of some 350,000 civilians into Spanish Sahara, and Spain withdraws from the territory.
1976–present: Western Sahara remains disputed, with Morocco administering most of it while the Polisario Front's Sahrawi Arab Democratic Republic claims independence; a 1991 UN ceasefire held until 2020.