The reign of the 19th century Afghan king Shah Shuja Durrani and that of the current president, Hamid Karzai, are alike in several ways; so is the geo-political scenario, according to historian William Dalrymple.

He made the remarks during a reading of his latest book, The Return of a King: Shah Shuja and the First Battle for Afghanistan, at the Jaipur Literature Festival on Sunday.

At the discussion later, Mr. Dalrymple noted how the situation that prevailed in the 19th century was being played out all over again in the present-day Afghanistan.

Today, the U.S. was committing the same mistakes imperial Britain did, and the country’s geo-politics was responding in very similar ways, he said. “The same cities are seeing an exact replay of what happened hundreds of years ago.”

Despite the striking similarities, one major difference between the two rulers was that “Hamid Karzai is much more popular than Shah Shuja was.”

Mr. Dalrymple said that while visiting Afghanistan on several extended trips from 2006 while researching for his book, he found a huge body of material on the Anglo-Afghan wars. “The Anglo-Afghan wars are to the Afghans what the freedom struggle is to you guys [the Indians]. The first Anglo-Afghan war was the greatest catastrophe suffered by the British army.”

In 1837, the British under Lord Wellesley conquered more of India than Napoleon had of Europe, and were looking to move up north, while Russians were moving down south. Both countries were on a collision course, he said.

Later, Henry Rawlinson, a British army officer who was the political agent of Kandahar in 1940, found Russian Cossacks in the Kandahar desert, in the first piece of intelligence that suggested Russia had designs on Afghanistan.

“This nugget of intelligence was to the Afghan situation what yellowcake was to the invasion of Iraq,” Mr. Dalrymple said.

Initially, the British invasion under Lord Auckland, meant to halt the Russian advance before they barrelled up towards the Khyber and then India, went really well. But it suffered a humiliating defeat as local resentment built up.

“The British were thrilled with the ease of their victory and loved Afghanistan and its climate. They introduced cricket in the country and even considered moving their summer capital from Shimla to Kabul,” Mr. Dalrymple said. But then, they started doing what all armies did — taking interest in the local women; this caused a great deal of resentment, with the Afghans fearing that the British were turning the country into a huge brothel.

Things came to a head when “Alexander Burnes, a British spy, seduced the mistress of a powerful Afghan noble, Abdullah Khan.”

The Afghans decided to teach the British a lesson before “the British rode the donkey of their desires into the field of stupidity” and waged jehad against them under the leadership of Abdullah Khan and Wazir Akbar Khan. The Afghans captured their food as well as arms on the very first day, and on the fifth day, they had effectively won. Burnes was killed in his house.”

Later, the British, who were hounded out of the country back to India, dispatched a force with instructions to “butcher and conquer,” he said.

The British soldiers marched up to Kabul, killing and raping in village after village. It was the most disgraceful, and everyone in Afghanistan, even those in villages, knew this story.

“The Americans know that their game in Afghanistan is over; only their politicians keep denying it,” Mr. Dalrymple said. “A village elder at Jagdalek, a village deep inside Taliban territory, told me ‘this is the last day of Americans in Afghanistan, the next is China’.”