During the cool, early hours when Annie Heckenberger likes to go running, the sidewalks and streets around her home in Chinatown are usually quiet and uncongested. But one morning last summer, as she reached the corner of 12th and Race streets, she suddenly found herself face to face with a speeding bicyclist.

“He came flying around the corner on the sidewalk and right into me,” she recalled. “Luckily, I’m the slowest runner in Philadelphia, so I was able to put my arms out and grab his handlebars and stop him. Apparently, I have quick reflexes at 5:45 in the morning.”

Heckenberger is a cyclist herself and was sympathetic to the rider, who she said was just as surprised as she was and immediately apologized. When she mentioned the encounter on Twitter, some of her followers were less accommodating. “Hope you’re okay!” one wrote. “I hate sidewalk cyclists. Unless you’re under the age of 10 and living in the burbs, it’s just not cool.”

Uncool, perhaps. Illegal, definitely: Bicyclists age 13 and older are barred from riding on sidewalks in most of Philadelphia, and no bicycling is allowed on sidewalks in Center City. The fine is $50. The law is almost never enforced, however. Four citations were issued for sidewalk riding in 2016,15 in 2017, and five so far this year, according to data from the Philadelphia Police Department. In New York, meanwhile, police issued 214 civil summons and 46 criminal summons for sidewalk riding in just the last three months of 2017.

On rare occasions, the Philadelphia police boost enforcement in targeted areas, as they are doing currently in Center City as part of a Vision Zero pilot project that installed bike lanes on John F. Kennedy Boulevard and Market Street.

Some cyclists use sidewalks occasionally. Others do routinely, drawing complaints from pedestrians who fear being hit or resent having to make way for moving vehicles on areas meant for slower foot travel. On roads without bike lanes, more than one in five bicyclists ride on sidewalks, a number that has remained consistent over several years, according to annual counts conducted by the Bicycle Coalition of Greater Philadelphia.

Deborah Schaaf, a former transportation planner for the city and co-chair of the pedestrian advocacy group FeetFirstPhilly, said her organization often hears from older residents who are are afraid of sidewalk bicyclists. “With senior citizens, [it’s] `if we get knocked down and injured, we’re not going to heal that fast, and maybe not at all,’ ” she said. “Another theme we hear a lot is, ‘The bicyclists, they’re just arrogant lawbreakers. They don’t care about the laws.’ Which is true of many; of course, it’s also true of a lot of other road users.”

To be sure, sidewalk bicycling is a minor issue compared to the constant threat to pedestrians and bicyclists of injury or even death from auto collisions. Motorists who don’t yield to those on foot, along with sidewalk obstructions, are pedestrians’ top concerns by far, according to surveys by FeetFirstPhilly. When it comes to bikes, pedestrians are more concerned about cyclists who blow through stop signs and stoplights than about those on the sidewalk, the group said. In the very rare cases when pedestrians have died in bicycle collisions, the accidents have occurred on the street, not the sidewalk.

Cycling on Philadelphia’s sidewalks has actually declined over the past several years, even as bicycling has increased overall, according to the Bicycle Coalition. It fell from 7.4 percent to 4.5 percent of riders from 2012 to 2016, with much of the decline occurring on roads with bike lanes.

However, counts on streets without bike lanes found that sidewalk riding held steady on those roads at just over 20 percent bicyclists, and it remains an irritant and nagging safety issue for some people. As Schaaf noted, the persistence and ubiquity of sidewalk riding is often cited by bicycling critics, who lump it in with other behaviors that they find annoying but are actually legal, like biking in the middle of the street.

When the city put up signs on 13th and 15th streets in South Philadelphia last year marking them as priority bicycle corridors, one vocal detractor of the move mentioned a long-ago sidewalk collision as a reason for her lifelong disdain for bicyclists. Jody Della Barba, a city employee who was once Frank Rizzo’s secretary, said that 50 years ago an aged relative was hit by a bike on the sidewalk, broke her hip, and died in the hospital three weeks later.

“I see stuff like this every day,” she told Philadelphia magazine, referring to violations by bicyclists. “I was walking down Chestnut Street, there are all these people riding on the pavement. Adults. Adults riding bikes in neighborhoods on pavement.”

A Facebook post quoting Della Barba’s demand for increased bike enforcement drew hundreds of responses. “Not sure how many bike lanes are in the city. Everyone is riding on the sidewalk,” resident Ray Weikel wrote. “Got hit by a bike twice on the pavement, told them where the bike lane is. They are afraid to go in the street. Nothing you can do. Lose-lose situation.”

Many bicyclists ride on the sidewalks at least occasionally, including those who say they are otherwise conscientious about following the law. Taking a quick break in her bike commute up 13th Street Friday morning, South Philadelphia resident Olinshar Nguyen said she sometimes rides or walks her bike on the sidewalk to avoid street hazards.

“It’s usually because something’s blocking the road,” said Nguyen, who works at Comcast. “If it’s something like Broad Street, where there’s a wide sidewalk, I might ride there, and where there are trolley tracks. But I generally don’t ride on the sidewalk.”

In a discussion last month in Reddit’s r/phillycycling group, commenters mentioned a number of reasons for using sidewalks, such as lacking confidence to bike in the street. One person said he rides the sidewalk up a one-way street rather than make a two-block detour, and he moves to the sidewalk when a bike lane is blocked and there’s car traffic. Another wrote that sidewalk riding even for a block is “awful,” but said he did it briefly one day to get around police activity in the street.

“If people are over the age of 12, then obviously we don’t want them to ride on the sidewalk,” said Randy LoBasso, the Bicycle Coalition’s communication manager. “Sometimes, there are occasions where people have to get on the sidewalk, and we encourage them when that happens, even if they’re gliding along for half a block or so, to get off their bike and walk it to a safe area. The reason why people ride on sidewalks, generally speaking, is because they don’t feel safe on the street.”

Though bicyclists may perceive the street as more dangerous, research has consistently found that taking the sidewalk is actually “much less safe,” as the authors of a 1994 study wrote. That study, of bicycle-car collisions in Palo Alto, Calif., found that the average sidewalk cyclist was 1.8 times more likely to be in an accident than a non-sidewalk rider, probably because a motorist didn’t see the rider when entering the road at an intersection. For adult bicyclists traveling on the sidewalk against the direction of traffic, the risk of a collision was 5.3 times higher.

“Sidewalk bicyclists are more likely than roadway bicyclists to be obscured at intersections by parked cars, buildings, fences, and shrubbery; their stopping distance is much greater than a pedestrian’s, and they have less maneuverability,” the researchers wrote.

A 1998 study of commuter cyclists in Ottawa and Toronto, Canada, found that sidewalk riders had more collisions, falls, and injuries than non-sidewalk riders, including a higher rate of collisions with other cyclists.

Critics of bicyclists such as Della Barba have called for stricter police enforcement to reduce sidewalk riding and other violations. LoBasso said that most people have violated road-use regulations at some point, and that enforcement alone will not improve safety.

Instead, LoBasso said, the Bicycle Coalition has sponsored a “Bike Nice” campaign to educate riders about cycling laws and is pushing for more bike lanes, particularly parking-protected lanes like those just created in Center City, which make riders feel safer in the street.

“Our mission is to make it so people feel safe and are safe and are comfortable riding in the street. The issue, if it is an issue, of people riding on a sidewalk will essentially solve itself as that mission is realized,” he said.

The Bicycle Coalition’s bicyclist counts appear to support the argument for more bike lanes to reduce sidewalk riding. After the city’s first one-way parking-protected lane was created on Chestnut Street between 34th and 45th streets in August 2017, the number of observed sidewalk cyclists decreased by half along that stretch, according to the organization.

The experiences of other cities suggest that the availability of protected lanes and other bike-friendly infrastructure will become even more important if the number of bicyclists in Philadelphia continues to grow, as may happen if dockless bike-share programs debut next year. In Chile’s capital, Santiago de Chile, the number of bicyclists has soared but infrastructure has not kept up, resulting in new dangers to pedestrians: A study found that, in some spots, 90 percent of bikers were on the sidewalk, reportedly making pedestrians feel “increasingly besieged.”

In Copenhagen, Denmark’s capital, some pedestrian advocates have said the city’s robust cycling culture makes sidewalks risky for retirees and older people. Sixty-two percent of that city’s residents bike to work or school, according to the Cycling Embassy of Denmark, amplifying the impact of violations far beyond what is seen in Philadelphia.

“We do have a lot of cyclists, but I don’t think we’re at the point where that’s happening,” LoBasso said.

Bicyclists and pedestrians said one route where competition for space does regularly result in collisions and near-misses is the Schuylkill Trail, which is a multi-use walking path designated for both pedestrians and cyclists, rather than a pedestrian-only sidewalk. LoBasso said he was biking on the trail last month when another cyclist passed him and clipped a woman who was walking.

The woman said it was the second time she’d been hit by a bicyclist, LoBasso said. The cyclist began arguing with the woman until he intervened, LoBasso said. The man apologized, he added.