Mr Carter’s visit comes as his top commander there, General John Campbell, voiced concerns that foreign fighters from Syria and Iraq are joining with Afghans who have declared loyalty to IS in the east, near the Pakistan border.
Officials have been warning for some time that while the presence of IS has been small, it is attracting disaffected members of the Taleban. Mr Campbell said supporters of IS are trying to establish a regional base in Jalalabad.
Fuelling those concerns is a new Pentagon report saying that the Taleban has been emboldened by the reduced US military presence in Afghanistan and attacks increased this year.
Mr Carter is planning to meet with his military commanders and troops. He is on a week-long visit to the region, and has spent the past two days in Iraq.
There are about 9,800 US troops in Afghanistan, including some who are involved in counterterrorism missions. In October, at the urgings of his military commanders, president Barack Obama announced that he would keep troops levels steady through most of next year. By the end of 2016, rather than draw down to a Kabul-only US military presence of about 1,000 troops as previously planned, Mr Obama decided the US will maintain 5,500 troops in Kabul and Bagram.
The latest report on violence in the country said Mr Obama’s decision reflects the need to give Afghans more time to develop a credible army.
According to a senior defence official, elements of the Taleban in eastern Afghanistan feel threatened by IS’s growth there and it has created a new dynamic in the region.
Often bad weather and difficult travel, particularly in the north and east, have slowed the fighting in the winter months.