ENCOURAGED BY smart urban transit policies, the District of Columbia has seen a surge in the number of bicyclists. It’s a trend that should be celebrated and fostered. At the same time, it spotlights the need for better public education and enforcement of traffic rules to prevent accidents.

Initiatives to make the city bike-friendly were a hallmark of former Mayor Adrian M. Fenty (D) and his forward-thinking director of transportation, Gabe Klein. An innovative bike-sharing program was introduced and expanded, city streets were reengineered, bike lanes were laid down, and a vigorous public relations campaign was launched to cajole people out of their cars. Judging by the numbers — and helped by spiraling gas prices — it has worked. The city’s annual snapshot of bicycle ridership showed an 80 percent increase in daily bicycle ridership from 2007 to 2010.

Disturbingly, though, the increase has been accompanied by a rise in accidents. Figures from the city’s transportation department show a 28 percent increase in cyclist injuries and fatalities from 2009 to 2010. Some of that may be attributed to better record keeping by authorities, but those familiar with cycling say there’s no denying that more cyclists on the roads have meant more accidents. A 2004 city report on crashes showed cyclists were slightly more likely than motorists to be at fault in a crash, spotlighting factors such as failure to yield right of way or cyclist inattention.

Before cyclists get off their bikes to e-mail us their complaints about motorists, we’ll stipulate there is plenty of blame to go around. There are drivers who are churlishly unwilling to share the road or are unaware of the rights of cyclists (yes, there are circumstances in which they can claim a traffic lane). That said, there are too many instances of cyclists who think that the sidewalks belong to them or that adhering to laws by stopping at red lights or stop signs is optional. Keep in mind that it’s the cyclist who is more apt to come out the loser in a collision with a car; last year there were two cyclist fatalities and 336 cyclist injuries.

The Washington area’s spring StreetSmart campaign, which featured increased public education and enforcement of traffic laws to highlight pedestrian-cyclist safety, was commendable but has come to an end. Traffic safety laws need to be enforced year-round. We would urge city officials who seek to make the District more bike-centric not to shirk on getting people — no matter if they are driving or riding — to follow the laws.