IBN TULUN MOSQUE – History, Legends & Hidden Treasures

A view down a long interior arcade at Ibn Tulun Mosque, Cairo, with rows of pointed arches receding into the distance over a faded green carpet.
Ibn Tulun Mosque: Built by a Sultan with the treasures of a Djinn

If you only had time to visit one mosque in Cairo, I would point you straight to the Ibn Tulun Mosque — not because it’s the biggest or the grandest, but because it’s the oldest, the most atmospheric, and in many ways, the most mysterious.

Dating back to the 9th century, Ibn Tulun Mosque is the second oldest mosque in Cairo that survives in its original form.  It was built by Ahmed Ibn Tulun, the ruler of Egypt at the time, and it’s a place that whispers its stories through the echo of your footsteps in the open courtyard, under the shadow of its unusual spiral minaret.

But it’s not just the age or architecture that pulls you in — it’s the strange, almost mythical energy of the place.  There’s a quiet here, even though you’re right in the heart of Islamic Cairo.  A stillness that feels ancient and sacred.A view of the exterior wall of the Ibn Tulun Mosque from the balcony of the Gayer-Anderson Museum, showing three arched doorways with semicircular steps and three large shuttered windows.

Viewed from the balcony of the historic Gayer-Anderson Museum, this perspective reveals the formidable yet elegant outer wall of the Ibn Tulun Mosque complex. The three doorways with their distinctive semicircular steps and the large shuttered windows illustrate the mosque’s unique fortified design, blending spiritual function with strategic presence in the heart of Cairo.

And then there’s the legends…

The Hill Where the Ark Landed?

The mosque was built on a hill once known as Gebel Yashkur, the Hill of Thanksgiving.  According to local folklore, this is the place where Noah’s Ark came to rest after the flood — not Mount Ararat, as the Bible says, but right here, in the middle of Cairo.

The story goes that Noah stepped out onto this hill and gave thanks — and that somewhere under the mosque lies the last of the floodwaters, sealed in a well, guarded by djinn.  Locals once believed that if you peered into the well too long, you’d either be pulled in or never seen again.

A bit of myth?  Of course.  But the Middle East doesn’t separate myth from place the way we do in the West.  Here, legend is part of the landscape — it enhances, not distracts from, the real history.

Gebel Yashkur’s title, the “Hill of Thanksgiving,” becomes known to us through other fabled events.  Legend speaks of God’s beckoning to Abraham on this very hill, tasking him with the horrific act of sacrificing his own son, Ismail.  Just as the blade was about to descend, an angel of God appeared, to say the Lord God would accept the sacrifice of a ram caught in a nearby bush in place of Ismail.  Thus, the hill now became a monument to gratitude.

It was also here that Moses witnessed the divine spectacle of a burning bush.  Guided by these extraordinary holy stories, Ibn Tulun, with an inspired heart, chose this sacred ground as the canvas for his own offering of thanks – the building of the oldest surviving mosque in Cairo.

👉 Explore all my post pharaonic stories from Egypt

The Architecture – A Spiral Into the Past

This is also the only mosque in Cairo with a spiral minaret, (in the photo below) more like what you’d find at the Al-Abbas Mosque in Samarra, Iraq, than anywhere else in Egypt. You can climb it — no stair railings, no fancy barriers.  Just a winding, slightly precarious stone path to the top, where you’re rewarded with a sweeping, uninterrupted view of Cairo’s rooftops.  I must admit I have never climbed it myself – for me that climb is something akin to a nightmare.

A wide view of the central courtyard of Ibn Tulun Mosque in Cairo, featuring the famous spiral minaret, a secondary minaret in the distance, and the domed structure covering the ancient well in the foreground under a blue sky.
The vast courtyard of Ibn Tulun Mosque, under a clear Cairo sky. The iconic spiral minaret rises against the blue, a testament to its founder’s vision. In the foreground, the domed pavilion shelters the ancient well that has provided water for over a millennium, standing at the very heart of this serene sanctuary.

Building Ibn Tulun mosque into Living Rock

In building his mosque, which covered six and a half acres, Ibn Tulun removed the top of the hill so that the foundations could be built into the living rock.  Everything around was destroyed at various times by earthquakes, except for the Mosque of Ibn Talun.  The mosque was finished in 879 AD, an amazing feat of engineering which has stood the tests of time.

It is said that when Ibn Tulun arrived to start his building work, the Ark of Noak was still on the hill.  He had it carefully dismantled and had the writings from the Koran carefully carved into every plank.  The planks were placed in succession around the inner walls and aisles of the mosque and are still there today.  Ibn Tulun built his palace against the wall of the mosque so he could access the mosque by a private door next to the minbar (pulpit in the mosque from which the Imam preaches).  Unfortunately, that palace was destroyed over time.

Treasures of the Djinn

The Ibn Tulun mosque teases the traveler with tales of secrets and treasures.  As legend tells us, a benevolent Djinn, Sultan al-Watawit, guided Ibn Tulun to a trove of unimaginable riches deep in the nearby Muqattam Hills.  These treasures made it possible for Ibn Tulun to bring all his dreams of what a mosque should be to life.  In this rugged terrain lies a deep pit, through which the retreating waters of Noah’s flood escaped.

The mouth of this pit is a well, situated next door to the mosque, in the house we know as the Gayer Anderson House.   And it is somewhere down that well that Sultan al-Watawit set up his abode to keep the remaining treasure safe.  Ibn Tulun had decided that this treasure should only be used for building the mosque, so when it was completed, he hid the remainder back where he found it, in the Muqattam Hills at the end of that secret passage.

Could it be that some of this treasure sometimes ends up in the water bucket of the magic well in Beit al-Kretliya (Gayer Anderson House) – dislodged by the ebb and flow of the underground water?

Coming back to the 20th century – the following is a scene from the James Bond film “The Spy Who Loved Me” where we see Roger Moore as James Bond walking through the Ibn Tulun Mosque and down the steps into the Gayer Anderson House next door.  The scene opens with the panoramic view of Cairo filmed from the Saladin Citadel in Cairo.

Is It Worth Visiting?

Absolutely — especially if you’re not just checking boxes on a sightseeing list.  Ibn Tulun Mosque and the Gayer Anderson House offer something different: a chance to feel Cairo’s soul rather than just observe its monuments.

I bring all my guests here, and it never fails to spark curiosity.  Whether it’s the idea of Noah’s Ark landing in Cairo, the whispers of djinn in the well, or simply the peacefulness of that vast courtyard, something always stays with you.

FAQs – Ibn Tulun Mosque

Q: Where is the Ibn Tulun Mosque located?
A: In the Sayeda Zeinab district of Cairo, Egypt — part of historic Islamic Cairo.

Q: Is the mosque open to tourists?
A: Yes, visitors are welcome, and entry is usually free, though donations are appreciated.

Q: What’s the connection between Ibn Tulun Mosque and Noah’s Ark?
A: According to local legend, the mosque sits on the hill where Noah’s Ark came to rest.  While not historically confirmed, the story adds spiritual significance.

Q: Can I combine it with other Cairo sights?
A: Definitely. It pairs beautifully with Gayer Anderson House next door, and a walk through Medieval Cairo

Discover More Hidden Gems in Egypt

If you’re planning your trip to Egypt, the essential travel guide will help you avoid common mistakes, and you will find an array of tours to suit your interests among the Mara House Luxor Tours to help you discover hidden stories and extraordinary places like this one — the kind of Egypt most tourists miss.