A pair of car bombs have torn through two different Baghdad neighbourhoods, killing at least 31 people and breaking what has been a period of relative calm since the end of the Muslim holy month of Ramadan.
The blasts were the worst to strike the Iraqi capital since the number of American troops in the country dropped below 50,000 and the US declared a formal end to combat operations.
The violence underlines the challenges Iraqi security forces face trying to stabilise Baghdad as US forces drawdown and Iraq's police and military assume responsibility for protecting the capital.
Sunday's deadliest attack took place in north Baghdad's Kazimiyah neighbourhood when a car bomb detonated near a branch office of the National Security Ministry in Adan square, killing at least 21 people and wounding more than 70, police and hospital officials said.
"It was a big explosion and dust and smoke filled my house," said Abu Shahad, who lives about 200 yards from the blast site. "I went out and saw a big black cloud hanging over the area where the bomb exploded, and I rushed there because I have relatives living there."
At least 10 people were killed in another car bombing in western Baghdad's affluent Mansour neighbourhood, said Army Brig Gen Ali Fadhal, who is responsible for the western half of the city. Another 10 people were wounded in the attack.
He said security officials were investigating whether the blast was the work of a suicide attacker in a car targeting a crowded commercial area near an AsiaCell store, one of Iraq's biggest mobile phone providers.
An eyewitness working in an office near the Mansour blast site said he heard a huge explosion that shattered windows in his office and brought a section of the ceiling down on one customer.
Security officials could be seen roaming the blast site in Mansour as ambulances and other vehicles blocked the road leading to the checkpoint near a branch office of the Ministry of National Security that police say was targeted.
There was no immediate claim of responsibility for the attacks.