Sensing post-World War I British fatigue, the frailty of British positions along the Afghan border, unrest in British India, and confidence in the consolidation of his power at home, Amanullah, the new ruler of Afghanistan, suddenly attacked the British in May 1919 in two thrusts. Although, Amanullah had written the British viceroy, rejecting British control of his foreign policy and declaring Afghanistan fully independent, the British were taken by surprise. Afghan forces achieved some success in the early days of the war as Pashtun tribesmen from both sides of the border joined forces with them. The military skirmishes soon ended in stalemate as the British recovered from their initial surprise. The war did not last long, however, because both sides were soon ready to sue for peace; the Afghans were unwilling to sustain continued British air attacks on Kabul and Jalalabad, and the British were unwilling to take on an Afghan land war so soon after the bloodletting of World War I. The month long war resulted in about 1000 Afghan dead and 2000 British and colonial deaths. What the Afghans did not gain in battle they gained ultimately at the negotiating table.
The British virtually dictated the terms of the 1919 Rawalpindi Agreement, a temporary armistice agreement that did provide-somewhat ambiguously-for Afghan autonomy in foreign affairs. Before signing the final document with the British, the Afghans concluded a treaty of friendship with the new Bolshevik regime in the Soviet Union; Afghanistan thereby became one of the first nations to recognize the Soviet government, and a "special relationship" evolved between the two governments.
The second round of Anglo-Afghan negotiations (1921) on a final peace were inconclusive. Although both sides were ready to agree on Afghan independence in foreign affairs, as mentioned in the previous agreement, the two nations disagreed on the issue that had plagued Anglo-Afghan relations for decades and would continue to cause friction for many more, that is, authority over the Pashtun tribes on both sides of the Durand Line. The British refused to agree to Afghan control over tribes on the British side of the line, while the Afghans insisted on it. The Afghans regarded the 1921 agreement as an informal one.