In Summer 407 AH/1016 AD, a wave of mass violence targeting Isma’ili Shi’i Muslims swept over Ifrīqiyah, a province of the Fatimid caliphate ruled by the Zirid dynasty and consisting of the territories of modern-day Tunisia, western Libya and eastern Algeria. Following their move to Egypt in the late 10th century, the Fatimid caliphs had appointed the Zirids, a dynasty of Sanhaja Berbers, as their governors and deputies in North Africa. Despite occasional outbreaks of violence, for much of the late 10th century there had been a delicate, albeit uneasy, coexistence between the various Muslim communities in Ifrīqiyah (Isma’ili Shi’is, Hanafis, Malikis, and Ibadis). The massacres of 1016 were therefore a cataclysmic set of events that shattered this heterogeneous society.
(Fatimid caliphate at its greatest extent)