The car rigged with explosives detonated in the mainly Shi’ite eastern district of Jamila, police said, as Iraqi government forces were preparing to declare victory over Islamic State more than 400 km (250 miles) further north in the city of Tal Afar.
It was not immediately clear if a suicide bomber had driven the vehicle to the target or if it was a parked car bomb, police sources said.
Medics and police sources said eight people died and 25 were wounded.
Interior Ministry spokesman Brigadier General Saad Maan said four people were killed and 12 wounded, including two policemen.
More about: #Baghdad