Hassan was appointed by the Umayyad caliph Abd al-Malik to lead the Arab reconquest of Ifriqiya (modern-day Tunisia) in North Africa. The chronology of Hassan's campaign and those of his immediate predecessors is uncertain as a result of the different dates provided by the medieval sources. The historian Mohamed Talbi asserts that the accounts of the two earliest sources, Ibn Abd al-Hakam (d. 871) and Ibn Qutayba (d. 889), confirmed by Ibn Asakir (d. 1175), are the "most probable ... agrees with the logical sequence of events and makes it possible to avoid inconsistencies". Prior to Hassan's appointment, Ifriqiya had fallen to the Berbers under Kasila and the Byzantines at the Battle of Vescera in 682. An initially successful attempt by Zuhayr ibn Qays al-Balawi to reconquer the region ultimately ended with Zuhayr's slaying and the Byzantines' capture of Barce in Cyrenaica in . Abd al-Malik, having consolidated his control over the Caliphate in the Second Muslim Civil War and resumed hostilities with Byzantium in 692, had troops to spare and equipped Hassan with 40,000 men. The deployment of an Arab force of this size to North Africa was unprecedented.