FERGUSON, Mo. — For four nights in a row, they streamed onto West Florissant Avenue wearing camouflage, black helmets and vests with “POLICE” stamped on the back. They carried objects that doubled as warnings: assault rifles and ammunition, slender black nightsticks and gas masks.
They were not just one police force but many, hailing from communities throughout north St. Louis County and loosely coordinated by the county police.
Their adversaries were a ragtag group of mostly unarmed neighborhood residents, hundreds of African-Americans whose pent-up fury at the police had sent them pouring onto streets and sidewalks in Ferguson, demanding justice for Michael Brown, the 18-year-old who was fatally shot by a police officer on Saturday.
When the protesters refused to retreat from the streets, threw firebombs or walked too close to a police officer, the response was swift and unrelenting: tear gas and rubber bullets.
“At a time when we must seek to rebuild trust between law enforcement and the local community,” Attorney General Eric H. Holder Jr. said, “I am deeply concerned that the deployment of military equipment and vehicles sends a conflicting message.”
Senator Claire McCaskill, Democrat of Missouri, and Senator Rand Paul, Republican of Kentucky, voiced similar sentiments.
But such opposition amounts to a sharp change in tone in Washington, where the federal government has spent more than a decade paying for body armor, mine-resistant trucks and other military gear, all while putting few restrictions on its use. Grant programs that, in the name of fighting terrorism, paid for some of the equipment being used in Ferguson have been consistently popular since the Sept. 11 terrorist attacks. If there has been any debate at all, it was over which departments deserved the most money.
Department of Homeland Security grant money paid for the $360,000 Bearcat armored truck on patrol in Ferguson, said Nick Gragnani, executive director of St. Louis Area Regional Response System, which administers such grants for the St. Louis area.
Since 2003, the group has spent $9.4 million on equipment for the police in St. Louis County. That includes $3.6 million for two helicopters, plus the Bearcat, other vehicles and night vision equipment. Most of the body armor worn by officers responding to the Ferguson protests was paid for with federal money, Mr. Gragnani said.
“The focus is terrorism, but it’s allowed to do a crossover for other types of responses,” he said. “It’s for any type of civil unrest. We went by the grant guidance. There was no restriction put on that by the federal government.”
While the major Homeland Security grants do not pay for weapons, Justice Department grants do. That includes rubber bullets and tear gas, which the police use to disperse crowds. A Justice Department report last year said nearly 400 local police departments and more than 100 state agencies had bought such less-lethal weapons using Justice Department grant money.
The military also sent machine guns, armored trucks, aircraft and other surplus war equipment to local departments. Compared with other urban areas, however, St. Louis County has received little surplus military equipment.
All these programs began or were expanded in response to the Sept. 11 attacks, when the authorities in Washington declared that local police departments were on the front lines of a global war on terrorism. Terrorism is exceedingly rare, however, and the equipment and money far outpaced the threat.
“You couldn’t say that back then with as much certainty as you can say that now, though,” said Frank J. Cilluffo, director of the Homeland Security Policy Institute at George Washington University. After Sept. 11, few people asked whether the police would use the equipment against protesters, Mr. Cilluffo said. “By and large, I don’t recall an outcry of any sort historically along these lines.”
In most instances, the government did not require training for police departments receiving military-style equipment and few if any limitations were put on its use, he said.
The increase in military-style equipment has coincided with a significant rise in the number of police SWAT teams, which are increasingly being used for routine duties such as conducting liquor inspections and serving warrants.
For years, much of the equipment has gone unnoticed. But as the wars in Iraq and Afghanistan have drawn down, police departments have been receiving 30-ton, mine-resistant trucks from the military. That has caught the attention of the public and caused controversy in several towns.
Nowhere has the deployment of military-style equipment been on starker display than this week in Ferguson.
The center of the protests is West Florissant Avenue, a run-down commercial strip that runs north-south. On it stands a nail salon, a barbecue restaurant and the burned-out remnants of a QuikTrip convenience store that looters targeted on Sunday night.
Late each afternoon, hundreds of people have trickled onto West Florissant, milling around on sidewalks and holding signs at television cameras.
As more protesters gathered, the police followed in greater numbers. They set up barricades of traffic cones so that cars could not enter. Protesters, usually young black men, have approached the police with their hands up in the air, a gesture that has become a taunt. (A witness to the shooting on Saturday said Mr. Brown had his hands up when he was shot.)
For three nights, the police made the same tactical move: When they determined that the protest was no longer peaceful, they used tear gas to force protesters off West Florissant and into the two residential neighborhoods on either side of it.
Once the protesters had been pushed onto side streets of small, one-story houses and low-slung apartment buildings, some of them said, they were effectively trapped on the wrong side of Florissant.
“Disperse! Go back to your homes!” the police shouted, often from the top of armored vehicles, through megaphones whose orders echoed throughout the streets.
“We don’t live here!” several people shouted back.
Keonta Finch, 21, waited hours for the police to open the barricade on Monday. “There’s no way out,” she said. “I can’t get home. I was just here to be peaceful, and now I’m stuck.”
Ms. Finch echoed a common complaint from protesters: The police seemed unable to differentiate between people in the crowds who were causing trouble and those who were not.
A woman who was identified as a pastor tried to calm some unruly members of the crowd on Wednesday; later that night, she was shot in the abdomen with a rubber bullet.
“Peaceful protesters are being conflated with rioters and looters,” said Christopher Leonard, who joined a group of quiet protesters on Wednesday evening.
Journalists have also been caught up by the police use of weapons. On Monday night, the police aimed directly at a group of photographers and a reporter as they covered the growing protest. One photographer was hit with a rubber bullet. A police officer on Wednesday tossed a tear-gas canister directly at a television crew for Al Jazeera.
On Wednesday night, in the neighborhood on the east side of Florissant, several dozen people were drawn to the site where Mr. Brown was shot, on a gently looping street called Canfield Court. They stood in small groups and shared stories of harassment by the police; some people sat on their front stoops and smoked marijuana.
Suddenly, just after 10 p.m., explosions boomed from what sounded like a few blocks away, stopping conversations cold.
“Firecrackers,” one woman said, staring in the direction of Florissant. “No, no, gunshots,” a man said, telling everyone to drop to the ground.
In a few minutes, it was clear what had happened: Tear gas was drifting into the neighborhood, enveloping houses, cars and people, who ran for cover in cars and houses, coughing and gasping as their eyes stung and vision blurred.
Police officials have said that they felt they had no choice but to use tear gas and rubber bullets. They could not allow looting to happen again, they said, and dispersing the crowds was the only way to stop it.
Chief Thomas Jackson of the Ferguson police defended the use of force against demonstrators during the past five days and said heavily armed officers with military-style equipment would continue to be deployed if the authorities determined that circumstances warranted it.
The tactical units will be out there if firebombs are being thrown at officers or if demonstrators are otherwise behaving violently, Chief Jackson said.
“If the crowd is being violent,” he said, “and you don’t want to be violent, get out of the crowd.”
An earlier version of a picture caption with this article misstated when the photo was taken and credited the wrong photographer. The image of the police formation was from Wednesday, not Tuesday, and the photo was taken by Mario Anzuoni, not Whitney Curtis.