Mohammad Afzal Khan overthrew him. In 1868, Mohammad Afzal Khan was himself overthrown and replaced as Emir by Sher Ali, who returned to the throne after spending few short years in exile in Russia. His return as Emir led to new conflicts with Britain. Subsequently, the British marched on 21 November 1878 into Afghanistan and Emir Sher Ali was forced to flee again to Russia, but he died in 1879 in Mazar-i-Sharif. His successor, Mohammad Yaqub Khan, sought solutions for peace with Russia and gave them a greater say in Afghanistan's foreign policy. Meanwhile, he signed the Treaty of Gandamak with the British on 26 May 1879, relinquishing solely the control of Afghanistan foreign affairs to the British Empire. However, when the British envoy Sir Louis Cavagnari was killed in Kabul on 3 September 1879, the British offered to accept Abdur Rahman Khan as Emir. The British concluded a peace treaty with the Afghans in 1880, and withdrew again in 1881 from Afghanistan. The British, in 1893, forced Afghanistan to consent to a new border, termed the Durand Line, which cuts right through the historic Pashtun settlement region, leading to British India annexing roughly a third of what had been Afghanistan. After the war, Emir Abdur Rahman Khan, who struck down the country reformed and repressed numerous uprisings. After his death in 1901 his son Habibullah Khan succeeded as emir and continued reforms. Habibullah Khan sought reconciliation with the UK, where he graduated in 1905 with a peace treaty with Russia, stretching for defeat in the Russo-Japanese War had to withdraw from Afghanistan. In the First World War, Afghanistan remained neutral, despite German and Ottoman efforts (Niedermayer–Hentig Expedition). In 1919 Habibullah Khan was assassinated by political opponents. Habibullah Khan's son Amanullah Khan was in 1919 against the rightful heir apparent Nasrullah Khan, the then Emir of Afghanistan. Shortly afterwards another war broke which lasted for three months. This war was ended with the Anglo-Afghan Treaty of 1919 after which, the Afghans were able to resume the right to conduct their own foreign affairs as a fully independent state. Amanullah Khan began the reformation of the country and was crowned 1926 Padshah (king) of Afghanistan and founded the Kingdom of Afghanistan. See also Durrani dynasty Barakzai dynasty Afghanistan–United Kingdom relations European influence in Afghanistan Invasions of Afghanistan Notes References Citations Works cited Further reading Clements, Frank. Conflict in Afghanistan: A Historical