The oldest of Morocco’s four imperial cities, it was founded on the banks of the Wadi Fez by Idrīs I (east bank, about 789) and Idrīs II (west bank, about 809). The two parts were united by the Almoravids in the 11th century to become a major Islamic city. Fes reaches its zenith as a center of learning and trade under the Marînids in the mid-14th century and has kept its religious primacy through the ages. The Treaty of Fes (March 30, 1912) established the French protectorate in Morocco.