In 2017, ISIL was largely defeated back from Iraq during the three-year battle, with the help of primarily Iran-backed Shia militias—Popular Mobilization Forces, reporting to the Iraqi prime minister since 2016—and the U.S.-backed Iraqi Armed Forces.