Suicide rates among middle-aged Americans have risen sharply in the past decade, prompting concern that a generation of baby boomers who have faced years of economic worry and easy access to prescription painkillers may be particularly vulnerable to self-inflicted harm.

More people now die of suicide than in car accidents, according to the Centers for Disease Control and Prevention, which published the findings in Friday’s issue of its Morbidity and Mortality Weekly Report. In 2010 there were 33,687 deaths from motor vehicle crashes and 38,364 suicides.

Suicide has typically been viewed as a problem of teenagers and the elderly, and the surge in suicide rates among middle-aged Americans is surprising.

From 1999 to 2010, the suicide rate among Americans ages 35 to 64 rose by nearly 30 percent, to 17.6 deaths per 100,000 people, up from 13.7. Although suicide rates are growing among both middle-aged men and women, far more men take their own lives. The suicide rate for middle-aged men was 27.3 deaths per 100,000, while for women it was 8.1 deaths per 100,000.