These two massive and outwardly similar buildings are located directly below The Citadel and within a few meters of each other, so it's best to consider them as one site. They are monumental examples of Mamluke architecture and engineering, and should be high on your list of things to see.
Madrasa of Sultan Hassan, named for al Nasir Hassan, who sat on the throne between 1347 and 1361 (with a break during his teens, when he was confined by an amir to the harem), was built in turbulent political times. Hassan's effective reign lasted until he was imprisoned in a military revolt and never seen again. His madrasa (school) and tomb took 4 years to build, and was more than twice the size of anything else being built at the time. Funding was made possible, ironically, by the bubonic plague that swept through Cairo in 1348, swelling the state treasury with the estates of its victims.
The massive building faced some engineering challenges: The western minaret collapsed before the whole project was finished, killing hundreds of people. The eastern minaret stayed up for 3 centuries before it collapsed, bringing about the collapse of the building's dome.
It didn't take very long after the place was finished for the military to put it to use, with its roof getting turned into an artillery platform from which to lob projectiles at The Citadel. While damage from the return fire was apparently evident in the 17th century, it seems to have been patched up since then.
The Madrasa of Sultan Hassan is a lovely place to visit any time of day, and it is particularly pleasant in the morning, when the light comes through the mausoleum windows. The entrance is dramatic and rather eerie, with a dark, twisting hallway decorated with stalactites leading to the main building. The main building is composed of four liwans (open halls) around a central courtyard, and a mausoleum is attached to the western liwan. The four Sunni schools each had a madrasa in one of the liwans, where students and teachers lived and studied. The mausoleum was designed as Sultan Hassan's final resting place, but his body was never found after the 1361 revolt that deposed him. Take time to sit in one of the liwans, looking up at the incredibly high arches and the lamps hanging on long chains swinging in the breeze.
The Mosque of Al Rifai was built 500 years after the neighboring madrasa, and was completed in 1912 in mock-Mamluke style. It's more straightforward architecturally than the madrasa and tomb next door, but the massive enclosed dome makes for a spectacular sense of space. The main point of interest for many here is the tomb of an important Sufi, Sheikh Ali Al Rifai, who is celebrated during an annual moulid (local festival for holy figures). The mosque also contains the tombs of several members of the Egyptian royal family (including Fuad I and Faruq) and of Mohamed Reza Pahlavi, the last Shah of Iran.
Back to School -- The madrasa, a state religious school, was introduced after the fall of the Fatimids in the 12th century and the return of Sunni government to Egypt under the Ayyubid dynasty. The four bays, or liwans, that you see in the courtyard represent the equal hand shown by the government to the four schools of Sunni religious thought named for four early Islamic religious thinkers Malik, Abu Hanifa, Ibn Hanbal, and al Shafa'i.