The short, useful answer: non-Muslims can enter one working mosque in Morocco (Hassan II in Casablanca), almost all of the country’s major medersas, and several royal mausoleums — some for free, the rest for a small fee that rarely exceeds 70–130 MAD ($7–$13). Every other working mosque is off-limits, a rule that is politely but firmly enforced.
That might sound limiting, but it is actually the opposite. The medersas that ring Morocco’s great mosques were built precisely to embody the same sacred geometry, tilework, and carved plaster as the prayer halls themselves — just accessible to everyone. Walk through the Ben Youssef Medersa in Marrakech or the Bou Inania in Fes and you are inside one of the finest examples of Islamic architecture on earth. The mosques next door are spiritually closed; the schools beside them are not, and they are extraordinary.
Below is a city-by-city breakdown of every significant site, with access rules, indicative costs, opening hours, and the practical things nobody tells you before you show up.