The US needs to commit several thousand more troops to Afghanistan in an effort to break the “stalemate” there, according to the top American commander in the country, potentially presenting President Donald Trump with his first major military decision.

John Nicholson, commander of US forces in Afghanistan, told the Senate armed services committee the western coalition of troops that remained in the country had a “shortfall of a few thousand”.

Mr Trump has so far said very little about his plans for Afghanistan, America’s longest war. From a peak of more than 100,000 US troops in the country in 2011, 8,600 remain in place.

Afghan government forces control about two-thirds of the country and have in recent months come under pressure from Taliban militants in several major cities, including Kunduz, which the Taliban nearly over-ran last year. Taliban attackers were beaten back by a heavy US-Afghan counterattack but the battle claimed the lives of 33 civilians, according to a US military investigation.

The Afghan administration is also struggling to defeat militants from other organisations, including Isis. This week Isis claimed responsibility for a suicide attack outside the supreme court in Kabul that killed at least 20 people.

On Thursday Mr Trump spoke by telephone to his Afghan counterpart Ashraf Ghani. According to the White House the US president “emphasised the ongoing importance of the US-Afghanistan strategic partnership”.

The statement added: “The leaders discussed opportunities to strengthen the bilateral relationship in areas such as security, counter-terrorism co-operation and economic development.”

General Nicholson suggested in his testimony to the Senate that he thought Mr Trump might be willing to increase troop numbers in the country, despite his previous criticism of US wars in the region.

Barack Obama was criticised while in office for prioritising troop reductions in Afghanistan no matter what the security situation on the ground.

Asked whether he thought Mr Trump might be more willing to take into account the security situation when deciding how many US troops should be in Afghanistan, Gen Nicholson responded: “Yes, sir.”

He also suggested James Mattis, the US defence secretary, might visit Afghanistan in the coming weeks.

In separate written testimony, meanwhile, Gen Nicholson criticised Russia — with which Mr Trump is keen to pursue closer relations — for strengthening the Taliban and undermining Nato in the country.

“Russia has become more assertive over the past year,” he said, adding that the Putin administration was “overtly lending legitimacy to the Taliban to undermine Nato efforts and bolster belligerents using the false narrative that only the Taliban are fighting [Isis]”.