Morocco has an exceptionally rich literary tradition and has attracted an unusual density of foreign writers. Storytelling is an ancient tradition — visit a weekly souk or Djemaa el-Fna in Marrakech and you'll still find storytellers at work.
The Sheltering Sky by Paul Bowles (1949) is the defining novel of Morocco as experienced by outsiders — an American couple slowly unravelling in the Saharan south. Bowles spent decades in Tangier and also translated and transcribed oral stories by Moroccan writers including Mohammed Mrabet and Larbi Layachi.
The Sand Child and The Sacred Night by Tahar Ben Jelloun are the best-known works by Morocco's most celebrated contemporary author. Ben Jelloun writes in French and lives in exile; his novels cut deeply into questions of identity, gender, and Moroccan society.
Dreams of Trespass by Fatima Mernissi is an essential memoir of growing up in a Fez harem in the 1940s, and doubles as a study of the enclosed world of traditional Moroccan women. Mernissi is Morocco's most important feminist scholar and sociologist.
Morocco That Was by Walter Harris — a British journalist who covered Morocco at the turn of the 20th century — remains one of the best historical accounts of the old sultanate before the French Protectorate. Vivid and opinionated.
The Spider's House by Paul Bowles (1955) is set in Fez during the final years of French rule and captures the city and the independence movement with sharp clarity.
In Morocco by Edith Wharton (1920) is a travel account written after her visit in 1917 — dated in its colonial assumptions but wonderful for descriptions of the cities and courts as they were before mass tourism.
Lords of the Atlas by Gavin Maxwell is a gripping history of the Glaoui dynasty — the Berber warlords of the High Atlas who allied with France and dominated southern Morocco until independence in 1956.
For contemporary travel, the Rough Guide to Morocco and the Lonely Planet Morocco are both solid. The Time Out Marrakech guide is useful for that city specifically.