BAGHDAD - Iraq's leaders are investigating the possibility of removing some of Baghdad's hundreds of much-hated checkpoints because of the improving security situation, the city's military spokesman said Tuesday.

Maj. Gen. Qassim al-Moussawi said that Prime Minister Nouri al-Maliki had asked commanders to evaluate the security situation in Baghdad and decide which of the roughly 870 checkpoints that dot the city could be removed.

The checkpoints are manned by Iraqi soldiers and police and designed to catch insurgents, but they also slow traffic in the congested city.

As security has improved, the prime minister started last year to remove some of the concrete blast walls that snake their way across the city, dividing neighborhoods and protecting buildings. The blast walls and checkpoints give the city, slowly recovering from years of violence, the air of being under a military occupation.

The decision is fraught with risk. Last year the removal of some of the walls was followed by a series of deadly blasts targeting government institutions, killing hundreds of people, and some of the concrete barriers went back up.

Baghdad residents generally abhor the checkpoints, which can make life unbearable for people going to work or school. Each Baghdad resident has a story about being stuck at a checkpoint for an hour or more.

"Checkpoints are a useless measure because they just ask people 'Are you carrying weapons?' and they say no and they check the trunk and that's all," said taxi driver Lwaa Adnan, 19, who carries students to Baghdad University.

When asked how many checkpoints he passed through on a daily basis, Adnan counted at least six he must negotiate to get from his neighborhood in northern Baghdad to the university in the southern part of the city.

Another driver described in frustration how high-ranking government officials in their security convoys with lights flashing bypass the long line of vehicles at the checkpoints while regular citizens are forced to stew, sometimes for hours.

Even more frustrating is that most Baghdadis don't even consider the checkpoints to be remotely effective.

Security forces at the checkpoints use a wandlike, handheld mechanism made in the United Kingdom that is supposed to be able to detect explosives in passing vehicles but that has been widely discredited. British authorities have banned its export to Iraq and Afghanistan after a report raised serious questions about it.

"This explosives detector just points if you have cleaning supplies or perfume in your car," said Amnea Waleed, 23, a college student.

Iraqi officials maintain the machines are useful and say that checkpoints have their place in maintaining security.

The captain in charge of one checkpoint in the Karradah neighborhood said that less than a week ago his men found a bomb attached to the undercarriage of a minibus and defused it.

But Capt. Odai Hamid Allah Ali said he understood that drivers got frustrated at having to wait in line and that removing the concrete blast walls and checkpoints could help bring back some of Baghdad's fabled beauty.