“Three suicide bombers tried to cross the checkpoint at Adan Square” in the Kadhimiyah neighbourhood, said Baghdad Operations Command spokesman Saad Maan.
The attack took place at around 5:30 pm (1430 GMT) on the square, one of the main access points for the Shiite shrine of Kadhimiyah, which attracts many visitors on Saturdays.
Saad Maan said the security forces at the checkpoint engaged the attackers and shot dead one of the bombers by the nearby railway while the other two blew themselves up.
A police colonel said one of the explosions was caused by a suicide car bomb.
He said at least 24 people were killed and 61 wounded in the attack. A source at the nearby Kadhimiyah hospital and an interior ministry official confirmed the casualty toll.
Adan Square has been repeatedly hit by attacks. More than 20 people died in a suicide bomb blast there in February.
The Islamic State jihadist group, which has controlled swathes of Iraq since last year, claims responsibility for most such attacks but there was no immediate claim for Saturday’s twin blasts.
According to figures released by the United Nations Mission in Iraq on Thursday, “a total of 717 Iraqis were killed and another 1,216 were injured in acts of terrorism, violence and armed conflict in September 2015.”
The Baghdad governorate alone accounted for 257 of the total deaths. The UN says its figures only account for the casualties that can be verified and are likely far below reality.