Iraqi forces recaptured territory from advancing Islamic State militants near the recently-fallen city of Ramadi on Sunday, while in Syria the government said the Islamists had killed hundreds of people since capturing the town of Palmyra.
A tank of the Iraqi army is seen on the outskirts of the city of Falluja, Iraq May 19, 2015.
The fall of Ramadi and Palmyra, on opposite ends of the vast territory controlled by Islamic State fighters, were the militant group's biggest successes since a U.S.-led coalition launched an air war to stop them last year.
The near simultaneous victories against the Iraqi and Syrian armies have forced Washington to examine its strategy, which involves bombing from the air but leaving fighting on the ground to local forces in both countries.
In a sharp criticism of Washington's ally, U.S. Defense Secretary Ashton Carter accused Iraq's army of abandoning Ramadi, a provincial capital west of Baghdad, to a much smaller enemy force.
"The Iraqi forces just showed no will to fight," he told CNN's State of the Union program. "They vastly outnumbered the opposing force, and yet they withdrew from the site."
Iraq's government, along with Iran-backed Shi'ite militiamen and locally-recruited Sunni tribal fighters, launched a counter-offensive on Saturday, a week after losing Ramadi. A police major and a pro-government Sunni tribal fighter in the area said they had retaken the town of Husaiba al-Sharqiya, about 10 km (6 miles) east of Ramadi.
"Today we regained control over Husaiba and are laying plans to make more advances to push back Daesh fighters further,” said local tribal leader Amir al-Fahdawi, using an Arabic acronym for Islamic State, also known in English as ISIS or ISIL.
“The morale of the (pro-government) fighters is high after the arrival of reinforcements and loads of ammunition," Fahdawi said. "Today's advance will speed up the clock for a major advance to regain control of Ramadi."
Planes were bombing Islamic State positions on the opposite bank of the Euphrates river, where the militants were launching mortars and sniper fire to prevent the pro-government forces advancing, Fahdawi and the police major said.
Days after taking Ramadi, Islamic State also defeated forces of the Syrian government of President Bashar al-Assad to capture Palmyra, home to 50,000 people and site of some of the world's most extensive and best-preserved Roman ruins.
The fighters have killed at least 400 people, including women and children in Palmyra since capturing the ancient Syrian city four days ago, Syrian state media said on Sunday.
It was not immediately possible to verify that account, but it was consistent with reports by activists that the Islamist fighters had carried out executions, leaving hundreds of bodies in the streets.
The Sunni Muslim militants have proclaimed a caliphate to rule over all Muslims from territory they hold in both Syria and Iraq. They have a history of carrying out mass killings in towns and cities they capture, and of dynamiting and bulldozing ancient monuments, which they consider evidence of paganism.
"The terrorists have killed more than 400 people ... and mutilated their bodies, under the pretext that they cooperated with the government and did not follow orders," Syria's state news agency said, citing residents inside the city.
Many of those killed were state employees, including the head of the nursing department at the hospital and all her family members, it said.
Islamic State supporters have posted videos on the Internet they say show fighters going room to room in Palmyra's government buildings, searching for hiding troops and pulling down pictures of Assad and his father.
The Syrian Observatory for Human Rights, which monitors violence in the country with a network of sources on the ground, says beheadings have taken place in the town since it fell but has not given an estimate for the toll among civilians.
It says at least 300 soldiers were killed in the days of fighting before the city was captured.
"A bigger number of troops have disappeared and it is not clear where they are," Rami Abdulrahman from the Observatory told Reuters.
Washington supports the government of Iraq but is opposed to Assad's government in Syria, making it more difficult to build a unified coalition against Islamic State, the most powerful force among Sunni Arabs in multi-sided civil wars in both countries.
In Iraq, government forces and Iran-backed Shi'ite militia advanced against the Sunni militants north of Baghdad in the Tigris river valley earlier this year, recapturing former dictator Saddam Hussein's home city of Tikrit.
But the insurgents responded by going on the offensive west of Baghdad in the valley of Iraq's other great river, the Euphrates, among the most hotly fought areas during the 2003-2011 U.S. occupation.
Washington worries that Baghdad's response of sending Shi'ite militia into the area for a counter-offensive could increase sectarian anger and play into Islamic State's claim to defend Sunnis from a Shi'ite dominated government in Baghdad.
In Syria, where a four-year civil war has killed 250,000 people and made 8 million homeless, Assad's government has been losing territory in recent months, both to Islamic State and to other Sunni groups, some of which are supported by the West.