Khan el-Khalili

Khan el-Khalili (خان الخليلي) is a famous bazaar and souq (or souk) in the historic center of Cairo, Egypt. Established as a center of trade in the Mamluk era and named for one of its several historic caravanserais, the bazaar district has since become one of Cairo's main attractions for tourists and Egyptians alike. It is also home to many Egyptian artisans and workshops involved in the production of traditional crafts and souvenirs. The name Khan el-Khalili historically referred to a single building in the area; today it refers to the entire shopping district.

The site of Khan el-Khalili in Fatimid times (10th-12th centuries)
Cairo was originally founded in 969 CE as a capital for the Fatimid Caliphate, an empire which by then covered much of North Africa and parts of the Levant and the Hijaz. Jawhar al-Siqilli, the general who conquered Egypt for the Fatimids, was ordered to construct a great palace complex to house the caliphs, their household, and the state's institutions. Two palaces were eventually completed: an eastern one (the largest of the two) and a western one, between which was a plaza known as Bayn al-Qasrayn. The site of Khan el-Khalili today was originally the southern end of the eastern Fatimid palace as well as the location of the burial site of the Fatimid caliphs: a mausoleum known as Turbat az-Za'faraan ('the Saffron Tomb'). Also located here was a lesser palace known as al-Qasr al-Nafi'i (today the site of the 19th-century Wikala of Sulayman Agha al-Silahdar).

Under the Fatimids, Cairo was a palace-city which was closed to the common people and inhabited only by the Caliph's family, state officials, army regiments, and other people necessary to the operation of the regime and its city. The first attempts to open the city to merchants and other outsiders took place in the later Fatimid period, on the initiative of powerful viziers. Between 1087 and 1092, Badr al-Jamali, the vizier under Caliph al-Mustansir, undertook the task of enlarging the city and building the stone walls and gates that still partly exist today. At the same time, he also opened the city to the common people, but the decision was quickly reversed. Between 1121 and 1125, al-Ma'mun al-Bata'ihi, vizier under Caliph al-Amir, undertook many reforms and construction projects, including the creation of a mint, known as the Dar al-Darb, and of a customs house for foreign merchants, known as the Dar al-Wikala. These were placed in a central location not far from the current site of the 15th-century Madrasa of al-Ashraf Barsbay. This introduced foreign trade into the heart of the city for the first time.

Development of Cairo as economic center (12th-14th centuries)
Cairo was only definitively opened to all people under the rule of Saladin, who dismantled the Fatimid Caliphate in 1171 and embarked on the construction of a new fortified Citadel further south, outside the walled city, which would house Egypt's rulers and state administration. The old Fatimid palaces in the city were opened up to redevelopment. This ended Cairo's status as an exclusive palace city and started a process by which the city became an economic center inhabited by everyday Egyptians and frequented by foreign travelers. At the same time, the nearby port city and former capital of Fustat, until then the economic hub of Egypt, was in a slow decline, further paving the way for Cairo's ascendance.

The main axis of Cairo was the central north-to-south street known as the Qasaba (now known as al-Muizz Street), which ran between the gates of Bab al-Futuh and Bab Zuweila and passed through Bayn al-Qasrayn. Under the Ayyubids and the later Mamluks, this avenue became a privileged site for the construction of religious complexes, royal mausoleums, and commercial establishments. These constructions were usually sponsored by the sultan or members of the ruling class. This is also where the major souqs of Cairo developed, forming its main economic zone for international trade and commercial activity thereafter.

An important factor in the development of Cairo's economic center was the growing number of waqf institutions, especially during the Mamluk period. Waqfs were charitable trusts under Islamic law which set out the function, operations, and funding sources of the many religious/civic establishments built by the ruling elite. Funding sources often included the revenues of designated shops or other commercial establishments. Among the early and important examples of this institution in Cairo's center was the complex of Sultan Qalawun, built in 1284–85, which included a madrasa, hospital, and mausoleum. A part of the complex's revenues came from a qaysariyya (a bazaar or market complex made up of rows of shops) that was built in front of the nearby Ayyubid-era madrasa of al-Salih. This qaysariyya was a prominent early example of the purpose-built commercial structures that came to be erected in Cairo under the Mamluks as part of a waqf. Qalawun's qaysariyya had a front on the Qasaba street while some of its shops were reached by an inner alley off the main street.

Foundation of Khan al-Khalili in the Mamluk period (14th-15th centuries)
Over many years, space along the Qasaba avenue steadily narrowed as new constructions encroached on it and open spaces disappeared. As the main street became saturated with shops and space for further development there ran out, new commercial structures were instead built further east, close to al-Azhar Mosque and to the shrine of al-Hussein, where some space was still available. Instead of hosting mobile market stalls that were assembled in open spaces, the city's souq areas were progressively replaced by fixed stone structures with built-in spaces for individual shops. This was partly a consequence of the authorities wishing to impose greater control on commercial activities: fixed structures could be counted, taxed, and regulated more easily than makeshift market stalls that could come and go. As the city became denser and space ran out, builders preferred to build multi-storied structures known as a khan (Arabic: خان) or a wikala (Arabic: وكالة), a type of caravanserai (inns for merchants). These types of buildings were centered around an inner peristyle courtyard where merchants could store their goods, while the upper levels were used as living quarters. Their street facades typically had spaces for shops at ground level. In this way, a commercial zone could extend around and between multiple khans.

By the time of Sultan Barquq (r. 1382–1399), the first Burji Mamluk sultan, Egypt had been significantly affected by the ravages of the Black Death but continued to be the center of great economic activity, with many commercial and religious buildings still being constructed at this time. During Barquq's first reign (1382–1389) his Master of the Stables (amir akhur), Jaharkas al-Khalili, demolished the Fatimid mausoleum (Turbat az-Za'faraan) to erect a large khan at the heart of the city. The khan became known as Khan al-Khalili, after his name. The name eventually came to denote the entire district. Al-Khalili reportedly disposed of the bones of the Fatimid royal family by throwing them into the rubbish hills east of the city.

Later Mamluk elites also built commercial structures in the vicinity and beyond. In Sultan Qaytbay's time one of his amirs, Yashbak min Mahdi, built the Rab' al-Badistan, an apartment complex for renters, just across from the Khan al-Khalili. Qaytbay himself built the Wikala of Sultan Qaytbay further east, near al-Azhar Mosque. By the late 15th century, the district around Khan el-Khalili had become the major center of foreign trade, including the sale of slaves and precious stones.

Re-development by Sultan al-Ghuri (early 16th century)
In the early 16th century, Sultan al-Ghuri, Egypt's last effective Mamluk sultan (r. 1501–1516), modified the layout of the whole district through a major campaign of demolition and new construction. In addition to building his own religious and funerary complex and a large Wikala named after him nearby, he demolished the original khan built by al-Khalili and rebuilt it in 1511. It became known as the Khan al-Fisqiya ("Khan of the Fountain") for centuries, until later being known as the Wikala al-Qutn ("Wikala of Cotton"). Al-Ghuri also reconfigured the adjacent area into a souq known as the Suq al-Nabulsi, which featured monumental stone gates. He also tried to impose a more regular grid plan on the surrounding district. Along with the stone gates, this sort of complex resembled what in Ottoman cities was known as a bedesten: a central bazaar where the most precious goods were sold and which often had roofed streets and locked gates at night (similar in some ways to a qaysariyya). It is possible that al-Ghuri's construction was done in imitation of such commercial complexes in major Ottoman cities, as this was a time when the Ottoman Empire was the major rival of the Egyptian Mamluk state and when Turkish merchants were increasingly prominent in Cairo.

What remains today from al-Ghuri's time is the Suq al-Nabulsi and its two ornate stone gates, as well as the façade and entrance of the Wikala al-Qutn. All these structures are located along the street known as Sikkat al-Badistan. The western gate was originally known as Bab al-Silsila but is known today as Bab al-Badistan, while the eastern gate, across from the Wikala al-Qutn 's entrance, was originally known as Bab al-Nuhhas but is now known also as Bab al-Ghuri.

Later history (16th century and after)
From the Mamluk period onward, the Khan al-Khalili area was made up of several major khans or wikalas grouped together, with souq streets existing between them. By the end of the Mamluk period in the early 16th century, there were 21 khans and wikalas in the district. From al-Ghuri's reign onward, the district became associated with Turkish merchants and during the Ottoman period (after 1517) the Turkish community of Cairo was centered here. The Wikala al-Qutn, which had replaced the original Khan al-Khalili structure, was inhabited by Turkish merchants. During the Ottoman period the prosperity of Cairo's souqs waxed and waned in accordance with local political conditions and international economic conditions. While Cairo was no longer an imperial capital, it still played a highly important role in the trade networks of the Ottoman Empire. New khans and wikalas continued to be built. The construction of new commercial buildings began to shift to the west of the Qasaba avenue as this was the only area where there was still space to build. New constructions were relatively rare in the 16th century but became more common again in the 17th century. Many old buildings were also restored, altered, or rebuilt, especially during the 18th century. In contrast with the Mamluk period, new religious complexes were rarely built, but many small mosques or prayer areas were added inside existing commercial buildings. By the end of the 18th century, just before Napoleon's invasion, some 39 khans and wikalas existed in the area of Khan al-Khalili and its adjoining districts. One late example of a large wikala built in the heart of Khan al-Khalili is the Wikala of Sulayman Agha al-Silahdar (or Wikala al-Silahdar), built in 1837 to replace a ruined Mamluk-era khan. It is still partially standing today, directly across from Bab al-Ghuri.

The district underwent significant modifications and re-developments again in the 19th and 20th centuries alongside major developments in the urban fabric of modern Cairo to the west. Al-Muski Street, a popular market street today, was created by cutting across the fabric of the old city to create a street roughly perpendicular to al-Muizz Street (the old Qasaba avenue). It runs from al-Hussein Square in the east to Midan 'Ataba ('Ataba Square) in modern downtown Cairo to the west. Among other important re-developments was the construction of about two dozen new residential blocs with ground-level shops in the eastern sector of the souq, initiated by the princess Shawikar in the late 1930s. This eastern area is now one of the most frequented by tourists.

Present day
The Khan el-Khalili today is occupied by local merchants and traders and is significantly geared towards tourists. Shops typically sell souvenirs, antiques and jewelry. The adjoining goldsmiths' souq is still important for locals. Although less widespread than in earlier days, many crafts workshops continue to operate within the bazaar (usually in the courtyards or upper floors of buildings) and in the surrounding districts, manufacturing some of the products sold here or exported elsewhere.

In addition to shops, there are several coffeehouses (مقهى), restaurants, and street food vendors distributed throughout the market. The coffeeshops are generally small and quite traditional, serving Arabic coffee and usually offering shisha. One of the oldest and most famous coffeehouses is El Fishawi's, established in 1773. The Khan al-Khalili proper is delimited by al-Muizz Street to the west, al-Muski Street to the south, and the Mosque/shrine of al-Hussein to the east, with its northern boundary less clear. In reality though, the bazaar area spreads beyond these limits and is closely integrated into the surrounding districts. For example, al-Muski street, which runs perpendicular to al-Muizz street and cuts across the south end of Khan al-Khalili, continues over a long distance and functions as a major souq street frequented by locals for much of its length.

In addition to the important Mosque and shrine of al-Hussein, Al-Azhar University and the Al-Azhar Mosque are also nearby. The monumental area of Bayn al-Qasrayn is also just northwest of the district. Some of its historic Islamic buildings were once maintained with the help of revenues from designated shops and commercial buildings in the area.

In literature
Naguib Mahfouz's novel Midaq Alley (1947) is set in an alley in Khan el-Khalili.

Pivotal events of Neal Stephenson's novel The Confusion (2004), which is the second book of his The Baroque Cycle series, are set in the caravanserai within Khan el-Khalili.

Mohammed Avdol, one of the main characters of Stardust Crusaders, the third part of JoJo's Bizarre Adventure, owns a fortune-telling shop in Khan el-Khalili.

P. Djeli Clark's short story The Angel of Khan el-Khalili takes place in this area and other parts of Cairo.

Terrorist attacks
The market was a target of terrorism during the spate of attacks in Cairo in April 2005. The suicide attack in the market, on April 7, killed 21 people (eleven Egyptians, two French tourists, one American, and seven foreigners of unidentified origin). It was the first attack in the series; this attack drove away tourists from Egypt in general and Khan el-Khalili in particular for some time.

The market was again a target of terrorism on 22 February 2009. In this attack a 17-year-old French girl was killed and 22 people were injured.