PHILADELPHIA — It started innocently enough seven years ago as an act of performance art where people linked through social-networking Web sites and text messaging suddenly gathered on the streets for impromptu pillow fights in New York, group disco routines in London, and even a huge snowball fight in Washington.
But these so-called flash mobs have taken a more aggressive and raucous turn here as hundreds of teenagers have been converging downtown for a ritual that is part bullying, part running of the bulls: sprinting down the block, the teenagers sometimes pause to brawl with one another, assault pedestrians or vandalize property.
On Wednesday, the police here said that they had had enough. They announced plans to step up enforcement of a curfew already on the books, and to tighten it if there is another incident.
They added that they planned to hold parents legally responsible for their children’s actions. They are also considering making free transit passes for students invalid after 4 p.m., instead of 7 p.m., to limit teenagers’ ability to ride downtown.
“This is bad decision making by a small group of young people who are doing silly but dangerous stuff,” Mayor Michael A. Nutter said in an interview Wednesday. “We intend to do something about it immediately.”
Flash mobs are not unique to Philadelphia, but they have been more frequent here than elsewhere. Others that resulted in arrests and injuries have been reported over the past year in Boston, South Orange, N.J., and Brooklyn.
Philadelphia officials added that they had also begun getting help from the Federal Bureau of Investigation to monitor social-media networks. And television and radio stations are helping to recruit hip-hop artists to make public service announcements imploring teenagers to end the practice.
In the past year, at least four of the flash mobs have broken out in the city, including one on Saturday in which roving teenagers broke into fights, several onlookers were injured and at least three people were arrested.
“It was like a tsunami of kids,” said Seth Kaufman, 20, a pizza deliveryman at Olympia II Pizza & Restaurant on South Street. He lifted his shirt to show gashes along his back and arm. He also had bruises on his forehead he said were from kicks and punches he suffered while trying to keep a rowdy crowd from entering the shop, where a fight was already under way.
“By the time you could hear them yelling, they were flooding the streets and the stores and the sidewalks,” Mr. Kaufman said.
The ad hoc gangs have scared many pedestrians off the streets.
City residents are also starting to complain about the number of unsupervised children, and child advocates are asking if there are enough activities to keep young people busy after school.
“We definitely need more jobs for kids, we need more summer jobs for kids, we need more after-school programming, and we need more parent support,” said Shelly Yanoff, executive director of Public Citizens for Children and Youth, a children’s advocacy group in Philadelphia.
Ms. Yanoff added that libraries and after-school programs had been reduced and a program for youth offenders had been cut sharply. On Friday, officials said, two preteenagers assaulted a woman as part of a violent game called “Catch and Wreck,” in which children pick out people who appear homeless and then beat them and take any money they have.
The police, who say these assaults are unrelated to flash mobs, arrested an 11-year-old boy and a 12-year-old girl in the attack. The police said they also planned to charge the boy in an attack on a 73-year-old man who was beaten and robbed in the same area on March 13.
The flash mobs have raised questions about race and class.
Most of the teenagers who have taken part in them are black and from poor neighborhoods. Most of the areas hit have been predominantly white business districts.
In the flash mob on Saturday, groups of teenagers were chanting “black boys” and “burn the city,” bystanders said.
In a Feb. 16 melee, 150 teenagers spilled out of the Gallery shopping mall east of City Hall during rush hour and rampaged through Macy’s, knocking down customers and damaging displays.
The police arrested 15 of the teenagers and, according to one report, some had not been allowed to call their parents six hours after they were detained.
Clay Yeager, a juvenile justice consultant and former director of the Office of Juvenile Justice and Delinquency Prevention in Pennsylvania, said he believed the flash mobs were partly a result of a decline in state money for youth violence prevention programs.
Financing for the programs has dropped 93 percent to $1.2 million in this year’s budget compared with $16 million in 2002. City financing for such programs has dropped to $1.9 million in the past three years compared with $4.1 million from 1999 through 2002, a 53 percent drop.
Mayor Nutter, who is black, rejected the notion that race or the city cut in services was a factor.
“I don’t think people should be finding excuses for inappropriate behavior,” Mr. Nutter said. “There is no racial component to stupid behavior, and parents should not be looking to the government to provide entertainment for their children.”
Violent crime in Philadelphia has dropped 12 percent and homicides have fallen 23 percent since 2008.
Bill Wasik, a senior editor at Harper’s who is credited with introducing the notion of a flash mob in 2003, said he was surprised by the new focus of some of the gatherings.
Mr. Wasik said the mobs started as a kind of playful social experiment meant to encourage spontaneity and big gatherings to temporarily take over commercial and public areas simply to show that they could.
“It’s terrible that these Philly mobs have turned violent,” he said.