Alawite sultan of Morocco, known for his piety, justice, and magnificent buildings. Proclaimed the sultan of Fez and Meknas in 1792, he subdued his rival brothers and extended his authority over the entire country by 1797. He confronted rebellions from Berber tribes and some Sufi orders and engaged in successive expeditions against his opponents in different parts on the country. By the end of his reign, the people of Fez rebelled against the sultan, who recaptured the city (1822). In an expedition against the Sharradi zawiyah (Sufi lodge) near Marrakesh, the sultan was captured and sent back to Marrakesh, where he died the same year. Erected several mosques, gates, bridges, and palaces in Morocco.