At least 17 Iraqi soldiers were killed in a fierce battle against jihadists south of Baghdad on Friday while bombs in and around the capital left another 16 people dead.
The clashes took place in Jurf al-Sakhr, a small Euphrates River town on a road linking Sunni insurgents strongholds in the west to Shiite holy cities south of Baghdad.
"Seventeen soldiers were killed and three wounded during clashes with insurgents in Jurf al-Sakhr that lasted two hours this morning," an army lieutenant told AFP.
An army medic confirmed the death toll, with both sources saying 23 jihadists from the Islamic State were also killed.
The mainly Sunni town, which lies in the north of Babil province, is the scene of almost daily fighting between pro-government forces and Sunni militants.
IS launched a sweeping offensive in northern Iraq on June 9, conquering the second city Mosul and large parts of the country's Sunni heartland.
Jurf al-Sakhr lies on the edge of what became known during a previous wave of sectarian bloodshed eight years ago as the "triangle of death."
The army and allied Shiite militia, such as Asaib Ahl al-Haq, take up positions in the town during the day but often pull back at night, which allows insurgents to plant roadside bombs.
The loss of Jurf al-Sakhr would threaten government control over one of only two main roads linking Baghdad to the southern Shiite heartland, including the holy cities of Karbala and Najaf.
Signup to our newsletter and follow us on Facebook and Twitter!
Another 17 people, including some IS fighters, were killed in a government air raid on Jurf al-Sakhr Monday.
In Baghdad, a car bomb exploded on a busy street of the large Shiite neighbourhood of Sadr City, killing at least nine and wounding 21, according to a police colonel and medical sources.
Three blasts near the Baghdad's central Kholani Square also went off near a Shiite mosque, killing five and wounding 16, according to the same sources.
And just south of the capital, in the town of Madain, at least two civilians people were killed and seven wounded in another bomb blast.
Figures compiled by the health, interior and defence ministries showed that 1,401 civilians, 185 soldiers and 83 policemen were killed in July.
The United Nations representation in Iraq provided a higher figure, saying at least 1,737 people were killed.
"I am concerned about the rising number of casualties in Iraq, particularly among the civilian population. Children and women are most vulnerable," top UN envoy Nickolay Mladenov said.
Iraq's scattered, moving frontlines and myriad fighting groups make independent verification of casualty figures very difficult.
The government's civilian tally includes an unknown number of volunteers who enlisted with government-backed Shiite militia.
The Islamic State does not divulge casualty figures.