NATO's Resolute Support mission in Afghanistan gave no further details, but the deaths came less than 24 hours after US Secretary of State Mike Pompeo made an unannounced visit to Kabul and said he hopes for a peace deal with the Taliban "before September 1".
"In accordance with US Department of Defense policy, the names of the service members are being withheld until 24 hours after notification of next of kin is complete," NATO said in a statement.
Three US troops, contractor killed in Afghanistan blast: official
The Taliban claimed in a statement they killed two American soldiers in an ambush in Sayed Abad district of southern Wardak province on Wednesday, but there was no immediate confirmation from NATO whether it was the same attack.
The blast brings to nine the number of US service members killed in Afghanistan so far this year, compared to 12 killed in all of 2018.
In his visit with President Ashraf Ghani, Pompeo said peace was Washington's "highest priority". Last September the US began a fresh push to bring the Taliban to the negotiating table to end America's longest war.
The next round of talks between the Taliban and the US are set to begin on June 29 in Doha.
The talks have centered on four issues: counter-terrorism, the foreign troop presence, an intra-Afghan dialogue, and a permanent ceasefire.
US officials have previously said they are hoping for a deal before the upcoming Afghan presidential elections, which have already been delayed twice and are now set for September.
The US now has some 14,000 troops in Afghanistan -- down from a peak of around 100,000 -- most of them deployed to train and advise Afghan counterparts.
Nearly 2,300 American soldiers have died and more than 20,400 have been wounded in the country since a US-led coalition ousted the Taliban in 2001.
COMMENTS
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ