How Old Is Morocco? From Ancient Roots to a Modern Kingdom

Ask a Moroccan how old their country is and you may get several answers, all of them true. A historian might say more than twelve centuries, counting from the first Moroccan state founded in 788. A political scientist might say seventy years, counting from independence in 1956. An archaeologist might smile and say three hundred thousand years, pointing to some of the oldest Homo sapiens fossils ever found, discovered in Moroccan soil. And an Amazigh grandmother in the Atlas might tell you that her people have lived here for thousands of years, long before any of those dates.

So, how old is Morocco? The honest answer depends on what you mean by “Morocco.” In this guide we walk through each layer of the country’s age, from prehistoric times to the modern kingdom, with the key dates, dynasties and places you can still visit today. By the end, you will understand why Morocco is often described as one of the oldest continuous states in the Mediterranean world, and why walking through its medinas feels like walking through time.

Morocco as a state is about 1,240 years old. Most historians date its foundation to 788 AD, when Idris I established the Idrisid dynasty, a state widely regarded as the foundation of the Moroccan nation. Since then, the country has been ruled by a series of Moroccan dynasties without interruption by a foreign empire, apart from the protectorate period of the twentieth century.

Modern, independent Morocco is about 70 years old, dating from 1956, when the French and Spanish protectorates ended. The land itself, however, has been home to humans for around 300,000 years, and the Amazigh (Berber) people have lived here for thousands of years.

What you measureStarting pointApproximate age in 2026
Human presenceJebel Irhoud fossils, around 300,000 years agoAbout 300,000 years
Amazigh (Berber) cultureThousands of years before the common eraSeveral thousand years
First recorded kingdomKingdom of Mauretania, centuries BCMore than 2,000 years
First Moroccan stateIdrisid dynasty, 788 ADAbout 1,238 years
Oldest university still operatingAl-Qarawiyyin, Fes, 859 ADAbout 1,167 years
Current ruling dynastyAlaouite dynasty, 17th centuryMore than 350 years
Independent modern stateIndependence in 195670 years
  • Around 300,000 years ago: early Homo sapiens live at Jebel Irhoud.
  • Thousands of years BC: Amazigh communities farm, herd and trade across the region.
  • First millennium BC: Phoenician trading posts at Lixus and Mogador.
  • Centuries BC to 1st century AD: the Kingdom of Mauretania, including the reign of Juba II.
  • 1st century AD: Rome creates the province of Mauretania Tingitana.
  • Late 7th century: Arab armies arrive and Islam begins to spread.
  • 788: Idris I founds the Idrisid dynasty.
  • 859: Fatima al-Fihri founds al-Qarawiyyin in Fes.
  • Around 1070: the Almoravids found Marrakech.
  • 12th century: the Almohads build the Koutoubia and the Hassan Tower.
  • 13th to 15th centuries: the Marinids rule from Fes.
  • 1578: the Saadians win the Battle of the Three Kings.
  • 17th century: the Alaouite dynasty unifies the country.
  • 1777: Morocco recognizes the United States.
  • 1912: the Treaty of Fes begins the protectorate.
  • 1956: independence.
  • 1957: Morocco becomes the Kingdom of Morocco.
  • 1999: King Mohammed VI comes to the throne.

In 2017, scientists announced a discovery that changed our understanding of human origins. At Jebel Irhoud, a site between Marrakech and Safi, researchers dated fossils of early Homo sapiens to around 300,000 years ago, making them among the oldest known remains of our species anywhere in the world. Before this discovery, the story of modern humans had been centered almost entirely on East Africa.

Morocco also holds important evidence of later prehistoric life. Caves along the Atlantic coast and in the north have revealed stone tools, shell ornaments and traces of early human behavior, and rock carvings in the south and in the High Atlas show hunters, animals and symbols left by people who lived here thousands of years ago, when the Sahara was greener than it is today. You can read more about that greener past in our article on when the Sahara will be green again.

Long before Romans, Arabs or Europeans arrived, North Africa was home to the Amazigh, often called Berbers. They are the indigenous people of the region, and their presence in Morocco goes back thousands of years. They farmed the valleys, herded animals across the mountains and plains, and built villages and fortified granaries that you can still see in the Atlas and the Anti-Atlas today.

Amazigh culture is still very much alive. Many Moroccans speak one of the Amazigh languages, Tamazight is an official language alongside Arabic, and the Tifinagh alphabet appears on public buildings and road signs. Traditional symbols are woven into carpets, painted on pottery and tattooed on the faces of older women in rural areas. To learn more, see our guides to who the Berbers are and Berber symbols.

From around the first millennium BC, Phoenician sailors from the eastern Mediterranean set up trading posts along the Moroccan coast. Sites such as Lixus, near Larache, and the island of Mogador, off Essaouira, became stops on trade routes for metals, salt, fish and purple dye. Later, the city of Carthage, in present-day Tunisia, took over much of this trade network.

Meanwhile, local Amazigh rulers formed the Kingdom of Mauretania, which covered much of northern Morocco and parts of western Algeria. Its kings had close relations with Rome. The most famous of them, Juba II, was a learned ruler educated in Rome who married Cleopatra Selene, the daughter of Cleopatra and Mark Antony. Under his reign, cities like Volubilis grew in wealth and importance.

In the first century AD, after the death of the last king of Mauretania, Rome turned the region into provinces. The western part, roughly northern Morocco, became Mauretania Tingitana, named after its capital Tingis, today’s Tangier. Rome controlled the north but never fully conquered the mountains and the south, where Amazigh tribes remained largely independent.

The best place to feel this period is Volubilis, near Meknes. Its triumphal arch, basilica and beautiful mosaics show how prosperous this frontier of the Roman Empire was, thanks to olive oil, grain and trade. Our guide to Volubilis explains how to visit the site.

Arab armies reached Morocco at the end of the seventh century, bringing Islam and the Arabic language. The process was neither quick nor simple: many Amazigh tribes resisted, while others converted and later played a central role in the spread of Islam into Spain from 711. In 740, a great Amazigh revolt pushed back the authority of the eastern caliphate, and the region split into several independent principalities.

Over the following centuries, Islam and Arabic culture blended with Amazigh traditions to create a distinctly Moroccan identity, one that you can see today in the country’s architecture, music, food and language. Our article on the languages of Morocco shows how this mix still shapes daily life.

The story of Morocco as a state begins with Idris ibn Abdallah, a descendant of the Prophet Muhammad who fled the Abbasid caliphate after a failed uprising in Arabia. He found refuge among the Awraba, an Amazigh tribe based near Volubilis, who recognized him as their leader in 788. Idris I founded the Idrisid dynasty and began building a new city on the banks of the Fes River.

His son, Idris II, expanded the city and made it his capital in the early ninth century. Fes quickly attracted refugees and scholars from Kairouan in Tunisia and from Andalusia in Spain, who gave the city its two historic quarters. In 859, a woman named Fatima al-Fihri founded the mosque of al-Qarawiyyin, which grew into a center of learning and is often described as the oldest existing, continually operating university in the world. Walking through the medina of Fes today, you are walking through streets that have been lived in for more than twelve centuries.

After the Idrisids, Morocco was ruled by a succession of powerful dynasties. Some of them built empires that stretched across North Africa and into Spain. Together they shaped the Morocco you see today.

DynastyApproximate datesLegacy you can still see
Idrisids788 to 974The founding of Fes and al-Qarawiyyin
Almoravidsc. 1040 to 1147The founding of Marrakech and an empire reaching into Spain
Almohads1121 to 1269The Koutoubia Mosque, the Hassan Tower in Rabat, the walls of Marrakech
Marinids1244 to 1465The beautiful madrasas of Fes, such as Bou Inania
Wattasids1472 to 1554A period of transition and Portuguese coastal forts
Saadians1549 to 1659The Saadian Tombs and the ruins of El Badi Palace in Marrakech
Alaouites17th century to todayMeknes under Moulay Ismail and the current royal family

The Almoravids and the founding of Marrakech

In the eleventh century, a religious and military movement of Saharan Amazigh tribes, the Almoravids, swept north from the desert. Around 1070 they founded Marrakech, which became the capital of an empire stretching from the Sahara to Andalusia. The city gave its name to the whole country: the word “Morocco” comes from Marrakech through Spanish and Portuguese. Discover more in our guide to the history of Marrakech.

The Almohads and the golden age of architecture

The Almohads, from the High Atlas, overthrew the Almoravids in the twelfth century and built some of Morocco’s most iconic monuments. The minaret of the Koutoubia Mosque in Marrakech and the unfinished Hassan Tower in Rabat date from this period. At its height, the Almohad empire ruled from the Atlantic to Tunisia and much of Spain.

The Marinids, Wattasids and Saadians

The Marinids made Fes their capital again and filled it with elegant madrasas covered in carved cedar, stucco and zellige. Later, the Saadians defeated a Portuguese army at the famous Battle of the Three Kings in 1578, and grew rich from trade across the Sahara. Their sultan Ahmad al-Mansur built the vast El Badi Palace in Marrakech, and the Saadian Tombs still amaze visitors with their decoration. Our article on trans-Saharan trade explains where much of that wealth came from.

The Alaouites: the dynasty that still reigns

The Alaouite dynasty rose in the Tafilalet region in the seventeenth century and unified the country under Moulay Rashid in the 1660s. His brother, Moulay Ismail, ruled for more than fifty years and turned Meknes into a grand imperial capital. The Alaouites still rule today, which makes them one of the oldest reigning royal families in the world. Learn more about the Moroccan royal family and who the King of Morocco is.

Here is a fact that surprises many American visitors: Morocco is often described as the first country to recognize the independence of the United States. In 1777, Sultan Mohammed ben Abdallah opened Moroccan ports to American ships, and in 1786 the two countries signed a Treaty of Peace and Friendship that is still in force, the longest unbroken treaty relationship in American history. The American Legation in Tangier, given to the United States in the early nineteenth century, is the oldest American diplomatic property abroad.

In the nineteenth century, European powers increased their pressure on Morocco. In 1912, the Treaty of Fes made most of the country a French protectorate, while Spain controlled zones in the north and the south, and Tangier later became an international zone. The sultan remained on the throne, but real power lay with the colonial administrations. During this period, new European-style districts were built next to the old medinas in cities like Casablanca, Rabat and Marrakech, which is why many Moroccan cities have both a medina and a “ville nouvelle.”

A nationalist movement grew in the 1930s and 1940s. When the French exiled Sultan Mohammed V in 1953, protests spread across the country, and he returned in triumph in 1955.

Morocco regained its independence from France on March 2, 1956, and from Spain shortly after, with Tangier rejoining the country later that year. In 1957, Mohammed V took the title of King, and Morocco became the Kingdom of Morocco. His son Hassan II reigned from 1961 to 1999, and the current king, Mohammed VI, came to the throne in 1999. Today, Morocco is a constitutional monarchy with a parliament and an elected government, and Rabat is its capital. Read our Rabat Morocco guide to discover the city.

Part of the confusion about Morocco’s age comes from the fact that the country has carried different names over the centuries:

  • Mauretania: the name used by ancient writers and by Rome for the region.
  • Al-Maghrib al-Aqsa: “the Far West,” the name used by medieval Arab geographers, because Morocco was the westernmost land of the Islamic world.
  • The Kingdom of Marrakech or Fes: how many Europeans described the country, after its capitals.
  • The Sherifian Empire: a name used for centuries, reflecting the rulers’ descent from the Prophet.
  • The Kingdom of Morocco: the official name since 1957.

Different names, but the same land and, for more than twelve centuries, a recognizable Moroccan state at its heart.

  • If you mean the land and its people: around 300,000 years of human presence and thousands of years of Amazigh history.
  • If you mean a Moroccan state: about 1,240 years, since the Idrisids in 788.
  • If you mean the current ruling family: more than 350 years of Alaouite rule.
  • If you mean the independent modern country: 70 years, since 1956.
  • If you mean the name “Kingdom of Morocco”: since 1957, when the sultan took the title of king.

All of these answers are correct. What makes Morocco special is that these layers are still visible side by side: Roman ruins, medieval medinas, royal palaces and modern cities.

CityApproximate originWhat to see from that era
TangierAncient, Phoenician and Roman TingisThe kasbah and the old medina
FesFounded 789, expanded under Idris IIThe medina of Fes el-Bali, al-Qarawiyyin
MarrakechFounded around 1070The Koutoubia, the medina walls, the Saadian Tombs
RabatAlmohad capital in the 12th century, on older foundationsThe Kasbah of the Udayas, the Hassan Tower
MeknesGrew into an imperial capital in the 17th centuryThe gates and granaries of Moulay Ismail
ChefchaouenFounded in 1471The blue medina and the kasbah
EssaouiraModern town planned in the 1760s, ancient island siteThe ramparts and the port
  • Volubilis: the best Roman ruins in Morocco, near Meknes.
  • Fes el-Bali: a living medieval city and a UNESCO World Heritage site.
  • Marrakech: Almoravid walls, the Koutoubia, the Saadian Tombs and the Bahia Palace.
  • Rabat: the Kasbah of the Udayas, the Hassan Tower and the Mausoleum of Mohammed V.
  • Meknes: Bab Mansour and the imperial city of Moulay Ismail.
  • Ait Ben Haddou: a fortified village on the old caravan route, see our Kasbah Ait Ben Haddou guide.

Many of these sites are included in our private tours, and our guides love sharing the stories behind them. For an overview of the empire’s rise and fall, read our article on the Moroccan Empire.

Comparing countries is never perfect, because borders and states change over time, but these rough reference points help put Morocco’s age in perspective:

CountryCommon reference dateCompared with Morocco (788)
EnglandUnified kingdom in the 10th centuryMorocco is over a century older
PortugalKingdom in the 12th centuryMorocco is about 350 years older
SpainUnion of the crowns in the late 15th centuryMorocco is about 700 years older
United StatesIndependence in 1776Morocco is nearly 1,000 years older
AlgeriaIndependence in 1962Morocco became independent six years earlier

This continuity is one reason Moroccans feel such a strong sense of national identity, and why the monarchy plays such an important symbolic role.

  • The name “Morocco” comes from Marrakech, but in Arabic the country is called al-Maghrib, meaning “the West.”
  • The red flag with a green five-pointed star was adopted in 1915. See our guide to the meaning of the flag of Morocco.
  • Al-Qarawiyyin in Fes was founded by a woman, Fatima al-Fihri, in 859.
  • Morocco was never part of the Ottoman Empire, unlike most of North Africa.
  • The Alaouite dynasty has ruled Morocco since before the United States existed.
  • Hire a licensed local guide in Fes and Marrakech; the medinas make far more sense with someone who knows the stories.
  • Combine Volubilis and Meknes in one day from Fes.
  • Visit the Saadian Tombs and El Badi Palace early in the morning to avoid crowds.
  • Look for small museums such as Dar Batha in Fes and Dar Si Said in Marrakech.
  • Cross the High Atlas to see kasbahs and ksour that guarded the old caravan routes.
  • Read a little before you go, so dates and dynasties come alive when you see the places.

If you want more inspiration, our list of facts about Morocco is a fun place to start.

When we guide travelers through Fes or Marrakech, the question “how old is this?” comes up constantly. A door in the medina may be three hundred years old, the street behind it a thousand, and the family selling bread next to it may trace its roots back even further. That is the real answer to how old Morocco is: old enough that history is not kept in museums, but lived in every day. The best way to understand it is to walk through it, slowly, with someone who can tell you the stories.

How old is Morocco?

As a state, Morocco is about 1,240 years old, dating from the Idrisid dynasty founded in 788. Modern independent Morocco dates from 1956, while humans have lived in the region for around 300,000 years.

When was Morocco founded?

Most historians date the founding of the Moroccan state to 788 AD, when Idris I established the Idrisid dynasty and began building Fes.

How old is the Kingdom of Morocco?

The title “Kingdom of Morocco” dates from 1957, when Sultan Mohammed V took the title of king, but the monarchy itself is much older. The current Alaouite dynasty has ruled since the 17th century.

When did Morocco become independent?

Morocco became independent from France on March 2, 1956, and from Spain shortly afterward.

Is Morocco older than the United States?

Yes. The Moroccan state dates back to 788, and the current dynasty was already ruling when the United States declared independence. Morocco recognized the United States in 1777.

What is the oldest city in Morocco?

Tangier and other coastal sites have ancient Phoenician and Roman origins. Fes, founded in 789, is the oldest of the imperial cities.

Who were the first people in Morocco?

The Amazigh, also called Berbers, are the indigenous people of Morocco and have lived there for thousands of years. Fossils at Jebel Irhoud show human presence around 300,000 years ago.

Was Morocco ever part of the Ottoman Empire?

No. Unlike Algeria, Tunisia and Libya, Morocco remained independent of the Ottoman Empire.

So, how old is Morocco? Old enough to hold some of the earliest traces of our species, to have been a kingdom for more than twelve centuries and to have one of the oldest ruling dynasties in the world, yet young enough as an independent modern state to be celebrating just seventy years. That mix of ancient and new is exactly what makes a trip to Morocco so fascinating.

Want to explore Morocco’s history with a local guide? Contact us, and we will design a private tour through its imperial cities, kasbahs and ancient sites.

Tours from Marrakech: Cross the High Atlas to Ait Ben Haddou and the dunes of Erg Chebbi.

Morocco Desert Tours: Camel trekking and a night under the stars in a Sahara desert camp.

Tours from Fes: The oldest medina in Morocco, then the Middle Atlas and the desert.

Tours from Casablanca: Begin at the Hassan II Mosque and travel through the imperial cities.

Tours from Tangier: Start in the north with Chefchaouen and the Rif Mountains.

Tours from Ouarzazate: Kasbahs, film studios and the gorges of the south.

Name
Lahcen Saadi, a professional local guide from the Exploring Morocco Trips team, in traditional attire in front of a 4x4 in the Sahara dunes

Your Local Experts

Our Moroccan team organizes private tours from every major city in Morocco: Marrakech, Fes, Casablanca, Tangier, Rabat, Agadir, Ouarzazate and more. Wherever you land, we pick you up and design your trip around your dates and interests.

Scroll to Top