Seven years resident in Granada. Specialist in Nasrid architecture, Al-Andalus history, and Andalusian walking routes.
Published
Updated
Granada did not begin with the Alhambra. The Nasrid palace complex that draws a million visitors a year was built two centuries after the city already had fortifications, cisterns, a functioning water network, and a street plan still legible today. The people who built that foundation were the Zirid dynasty — Sanhaja Berbers from North Africa who arrived after the Umayyad Caliphate of Córdoba collapsed in 1009, claimed the hilltop settlement on the Darro, and turned it into the capital of one of medieval Iberia's most surprising states.
In this article
The collapse that made Granada possible
The Umayyad Caliphate of Córdoba had kept al-Andalus under centralised control for three centuries. When it began to fracture in 1009, the fracturing was rapid and total. A series of civil wars — known collectively as the fitna — tore the Caliphate apart within two decades, and by 1031 it had ceased to exist as a political entity. What replaced it were the taifa kingdoms: small, independent principalities, each based around a city or a strong military leader, often bitter rivals of one another.
Zawi ibn Ziri arrived in al-Andalus in this context. He was the leader of a Sanhaja Berber clan that had been fighting as mercenaries for the Caliphate during the fitna, and he read the new political landscape with clarity. When the music stopped, he needed land and a power base. He found both in the region around the Vega de Granada — the fertile plain below the Sierra Nevada — where the old Roman and Visigothic settlement of Iliberis had long occupied the hill above the Río Darro.[1]
The existing settlement was called Medina Elvira, and it sat on the broader plateau to the west of what is now Granada's centre. Zawi ibn Ziri made a deliberate urban decision in 1013: he moved the administrative capital from Medina Elvira to the hilltop site across the valley, a position that was more defensible and sat at the convergence of the main routes through the area. He called it Gharnāṭa, from which the Spanish name Granada derives. Within a generation, the old city had emptied into the new one. The Albaicín hill, which the Romans had also inhabited, became the medina — the urban heart — of a new taifa state.
Timeline
1009
Caliphate collapses
The Umayyad Caliphate of Córdoba begins its final civil war. Within 22 years it ceases to exist as a political entity.
1013
Zawi ibn Ziri founds Granada
The Sanhaja Berber leader relocates the capital from Medina Elvira to the Albaicín hill, founding Gharnāṭa as the taifa capital.
1019
Habus al-Muzaffar takes power
Zawi's nephew consolidates the Zirid kingdom, stabilises its borders, and begins the urbanisation of the medina.
c. 1020
Samuel HaNagid enters royal service
The Jewish scholar and poet begins his rise through the Granadan court, eventually becoming the Zirids' chief administrator.
1037
Badis ibn Habus becomes ruler
The longest-reigning Zirid emir begins 35 years of territorial expansion and patronage. Samuel HaNagid is appointed grand vizier and military commander.
1066
Granada massacre
Joseph ibn Naghrella assassinated; most of the city's Jewish community killed. End of the Jewish Golden Age in Granada.
1090
Almoravid conquest
The last Zirid ruler Abdallah surrenders Granada to the Almoravids without resistance. The taifa period ends.
Building a city from the ground up
The Zirids inherited a hill with some existing occupation but no infrastructure adequate for a capital city. What they built between 1013 and 1090 was not decoration — it was the physical skeleton that every subsequent dynasty, including the Nasrids, used and extended.
The most important structure was the alcazaba cadima (Old Citadel), built on the highest point of the Albaicín ridge.[2] This was the political and military centre of the taifa state: the emir's residence, the treasury, the garrison. The Albaicín's highest point today still bears traces of its foundations, and the street pattern of the surrounding neighbourhood — the narrow, curved lanes that tourists photograph as picturesque — follows the street plan that Zirid urban engineers laid out in the 11th century. You are not looking at a naturally evolved medieval quarter when you walk those streets. You are looking at planned infrastructure.
Water was the other foundational work. The Zirids extended the acequia de Aynadamar, an irrigation channel that brought water from springs at Alfacar, roughly 8 kilometres north of the city, into the medina.[3] They built the first of the aljibes — the underground vaulted cisterns that stored this water close to where it was needed across the hillside. The largest medieval aljibe in the Albaicín, the Aljibe del Rey, dates to around 1038 under Badis ibn Habus.[3] Twenty-six of these cisterns survive today beneath the Albaicín's streets, and the system they formed was the engineering foundation on which the Nasrid city later grew.
The Puerta de Elvira — the western gate into the city, still standing at the foot of Calle Elvira — was built in this period as part of the Zirid fortification wall.[2] The gate's horseshoe arch visible today is a later Nasrid reworking, but the gate's position and function trace directly to the 11th-century boundary the Zirids drew around their capital. Walk through it now and you are passing through the same gap in the same line of defence.
Samuel HaNagid and the Jewish Golden Age
No episode in Zirid history is more remarkable, or more discussed, than the career of Samuel ibn Naghrillah, known in Jewish tradition as Samuel HaNagid (HaNagid means "the Prince"). He arrived in Granada around 1020, probably from Córdoba, following the collapse that had disrupted Jewish life across al-Andalus.[4] According to later accounts, he was initially working as a spice merchant near the palace, and his elegant Arabic script came to the attention of a court official who brought him into the Zirid administration.
Under Habus al-Muzaffar, he rose to become chief secretary and close adviser. When Badis ibn Habus took the throne in 1037, he appointed Samuel HaNagid as grand vizier — the most senior administrative and military position in the kingdom — and also, without precedent in any Muslim principality, as commander of the Granadan army.[4] For the next seventeen years, until his death in 1056, Samuel HaNagid ran the Zirid state, led its military campaigns, and negotiated its foreign alliances.
The scale of this achievement needs context. Medieval Islamic law operated a dhimmi system under which Jewish and Christian subjects could practise their religions but were excluded from positions of authority over Muslims. Samuel HaNagid's appointment violated that principle in the most direct way possible: a Jewish man commanded Muslim soldiers, directed Muslim officials, and represented the Zirid state in dealings with other Muslim rulers. His appointment was not universally accepted — religious conservatives in other taifa kingdoms denounced it — but Badis ibn Habus maintained it for nearly two decades.
In 1047, HaNagid led the Granadan army to a significant victory over the Taifa of Seville at the Battle of Ronda.[4] He conducted at least a dozen military campaigns in total. Between them, he wrote three major works of Hebrew poetry — Diwan Ben Tehillim, Ben Mishlei, and Ben Qohelet — as well as grammatical and Talmudic scholarship. The combination of active military command and serious literary output has no real parallel in medieval history, Jewish or otherwise. His son, Joseph ibn Naghrella, succeeded him as vizier after his death in 1056, and in the same year Badis annexed the Taifa of Málaga, reaching the territorial peak of Zirid power.[1]
Walking the Realejo today — the neighbourhood south of the Alhambra hill that was the medieval Jewish quarter, then called Garnata al-Yahud (Granada of the Jews) — you are tracing the geography of this community at its height.
The 1066 massacre and the end of the Golden Age
The conditions that made Samuel HaNagid's career possible — a dynasty willing to prioritise administrative competence over religious convention, a community confident enough to build institutions — did not survive the generation after him. His son Joseph ibn Naghrella inherited both the vizierate and, apparently, a talent for making enemies.
The Arabic sources that describe the events of 30 December 1066 are hostile to Joseph, accusing him of arrogance, of building a palace too close to the Alhambra hill (the detail may be symbolic), and of conducting Granadan foreign policy in ways that favoured Jewish interests over Muslim ones.[5] Whether these accusations were accurate or constructed after the fact is impossible to establish. What happened that day is not in dispute: Joseph ibn Naghrella was assassinated, and the mob that killed him then moved through the Jewish quarter of the city in an organised massacre.
The death toll from the Granada massacre of 1066 is given in contemporary sources as several thousand, though these figures are uncertain.[5] What is clear is that the Jewish community of Granada was destroyed as a functioning civic entity. The institutions that had made the city a centre of Hebrew scholarship — the academies, the communal governance structures, the patronage networks — were gone within a day. Hasdai ibn Shaprut had already defined the Córdoba period; Samuel HaNagid had defined the Granada one. After 1066, the centre of Jewish intellectual life in al-Andalus shifted east, to Zaragoza and then to the Christian kingdoms in the north. The community that slowly rebuilt under Nasrid rule would face its final rupture four centuries later, when the Alhambra Decree of 1492 ordered every Jew in Spain to convert or leave.
For the Zirids, the political consequences were not immediately fatal. Badis ibn Habus continued to rule until 1073 — thirty-five years total — and Granada remained one of the more stable taifa states. But the massacre had removed the administrative talent that had run the kingdom effectively, and the dynastic struggle that followed Badis's death between his grandson Tamim and his son Abdallah (who eventually prevailed) left the state weakened and divided.
The Almoravid conquest and the end of Zirid rule
The Almoravids were Sanhaja Berbers, like the Zirids — in fact the two groups shared distant ancestry — but they had built a very different kind of state. Where the Zirids were pragmatists who had governed al-Andalus's taifa politics for eighty years, the Almoravids had unified North Africa under a strict reformist interpretation of Maliki Islam and were expanding rapidly. They had crossed into Iberia in 1086 at the invitation of the taifa rulers who could not individually resist Alfonso VI of Castile. Having stopped Alfonso at the Battle of Sagrajas, they stayed.
For the taifa kings, the Almoravids were a cure that looked increasingly like the disease. The invitation had been military; the Almoravids interpreted it as political authority. One by one, the taifa states were absorbed. Abdallah ibn Buluggin, the last Zirid ruler, wrote a memoir in exile — the Tibyān — that describes the process with a resignation that reads as genuine.[1] He had watched the taifa states around him fall and understood that Granada's turn was coming. When the Almoravid army arrived in 1090, he surrendered without resistance and was exiled to Morocco. He died there years later, still writing.
The Zirid period had lasted seventy-seven years. In that time, Granada went from an administrative transfer point to the capital of a functioning state with city walls, a water system, a street plan, a Jewish intellectual community of international standing, and a building tradition that the Nasrids would later inherit and refine. The Almoravids and then the Almohads followed before the Nasrids arrived in 1238. Both are often treated as interruptions in Granada's history, something that happened between the Zirids and the Alhambra. The continuity of the urban fabric — the Albaicín's street plan, the aljibe network, the line of the old fortification walls — makes that framing hard to sustain.
Medieval stone towers and narrow winding streets of Granada's Albaicín quarter, the site of the Zirid dynasty's alcazaba cadima fortress, with dark stone walls and green vegetation against a bright Spanish sky
The foundations the Zirids poured are still under the city.
What survives and what to look for today
The Zirid period left no single monument with a ticket booth and an audio guide. What it left is structural: the layout of a neighbourhood, the position of a gate, the depth of a cistern.
The most direct encounter with Zirid Granada is the Albaicín itself. The quarter's street plan — the curves, the dead ends, the way lanes branch off unexpectedly at angles that make no sense on a modern grid — follows the 11th-century urban layout. The Zirids did not plan for cars or tourists. They planned for a hillside medina that needed defensible lanes, shade, and proximity to water. You experience that planning every time you get mildly lost up there.
The Puerta de Elvira, at the foot of Calle Elvira, marks the western edge of the Zirid city wall. The arch today is a 14th-century Nasrid reworking, but the gate's position in the wall line is original.[2] The aljibes scattered through the neighbourhood are the other physical layer: 26 survive, and several are accessible or at least visible from street level. The Aljibe del Rey, dating to around 1038, is the largest (capacity 300 m³).[3] The full network and the hydraulic engineering behind it are covered in the article on Albaicín aljibes.
For Samuel HaNagid specifically, the relevant site is the former Jewish quarter on the south side of the Alhambra hill — the area now called the Realejo. The medieval topography of Garnata al-Yahud is largely erased, but the street pattern and the position of later buildings follow the medieval plan. The article on the Realejo Jewish quarter maps what survives and what the neighbourhood looked like in the 11th century.
The Cuarto Real de Santo Domingo on the edge of the modern city centre is worth noting: it is a 13th-century Almohad structure, post-Zirid, but it preserves the architectural vocabulary that the Zirids used. Stand in its garden and you are seeing what Zirid domestic architecture would have looked like, if any of it had survived.
Nothing from the Zirid period is labelled as such in Granada's tourist infrastructure. That is partly because the Zirids have been overshadowed by the Nasrids, who built the thing everyone comes to see, and partly because their physical legacy is urban fabric rather than individual buildings. But the ground-level reality of walking the Albaicín — the gradient, the narrowness of the lanes, the sudden view south over the city from the ridge — is more Zirid than it is anything else.
FAQ about zirid dynasty granada
Who ruled Granada before the Nasrid dynasty?
The Zirid dynasty ruled Granada from 1013 to 1090, when the Almoravids conquered the city. After the Almoravids, the Almohad dynasty controlled Granada from the mid-12th century until 1238, when Muhammad I ibn al-Ahmar founded the Nasrid Emirate of Granada. The Nasrids held the city until 1492, when it fell to Ferdinand and Isabella.
What did the Zirid dynasty build in Granada?
The Zirids built the alcazaba cadima (Old Citadel) on the Albaicín hill, the city's first major fortification. They also constructed the network of aljibes (underground cisterns) that supplied the neighbourhood with water, extended the acequia de Aynadamar from the springs at Alfacar, and built the first sections of the city wall including the Puerta de Elvira gate. The Albaicín's street plan dates from this period.
Who was Samuel HaNagid and why was he important in Granada?
Samuel ibn Naghrillah (993–1056), known as Samuel HaNagid, was a Jewish scholar, poet, and statesman who served as grand vizier and military commander under Zirid ruler Badis ibn Habus from around 1037 until his death in 1056. His appointment was historically unprecedented: a Jewish man commanding a Muslim army and running a Muslim state. He led at least a dozen military campaigns, won the Battle of Ronda in 1047, and simultaneously produced three major collections of Hebrew poetry. His career defined the Jewish Golden Age in Granada.
What happened in the Granada massacre of 1066?
On 30 December 1066, Joseph ibn Naghrella — Samuel HaNagid's son and successor as vizier — was assassinated by a mob, and the attack spread through the Jewish quarter of the city. Contemporary sources record several thousand deaths, though the exact figure is uncertain. The Jewish community of Granada was effectively destroyed as a civic and intellectual entity. The event ended the city's Jewish Golden Age and shifted the centre of Jewish life in al-Andalus northward and eastward.
Why did the Zirid dynasty fall?
The immediate cause of the Zirid dynasty's end was the Almoravid military expansion across al-Andalus. The Almoravids, a Sanhaja Berber confederation from North Africa, had been invited into Iberia by the taifa rulers in 1086 to resist Castilian military pressure. Having won at Sagrajas, they stayed and absorbed the taifa states one by one. The last Zirid ruler, Abdallah ibn Buluggin, surrendered Granada without resistance in 1090 and was exiled to Morocco. Internal dynastic instability after Badis's death in 1073 had already weakened the state before the Almoravids arrived.
What is still visible from the Zirid period in Granada today?
No single Zirid building survives intact, but the physical legacy is extensive. The Albaicín's street plan follows the Zirid medina layout. The Aljibe del Rey, dating to around 1038, is the largest medieval cistern in the neighbourhood (300 m³ capacity). The Puerta de Elvira marks the position of the original Zirid city wall, though the arch visible today is a 14th-century Nasrid addition. The former Jewish quarter — the Realejo — preserves the position of the medieval Garnata al-Yahud, where Samuel HaNagid lived and governed.