The
Islamic conquest of Afghanistan (642–870) began in the middle of the 7th century after the
Islamic conquest of Persia was completed, when
Arab Muslims defeated the
Sassanid Empire at the battles of
Walaja,
al-Qadisiyyah and
Nahavand. The Muslim Arabs then began to move towards the lands east of
Persia and in 652 captured the city,
Herat. By 667, the
Afghan area was under invasion by the Arabs but in 683
Kabul and other parts of Afghanistan fought with resistance and completely routed the invading army which was led by the Governor of Seistan. The near-complete conversion of
Afghans to
Islam was during the period of the
Ghaznavids in the 10th century with
Kafiristan holding out until
Emir Abdur Rahman Khan conquered and forcibly converted them in the 1890s.