OAKLAND — Northern California counties are leading their Southern California counterparts in a dismal figure: the rate of young people killed by gun violence.

Monterey County ranked highest statewide in the homicide rate for victims ages 10 to 24, according to an analysis of 2012 crime statistics released Tuesday by the Violence Policy Center. San Francisco ranked second, San Joaquin County third and Alameda County fourth.

All four counties had more than 20 murders for every 100,000 young people, well above the statewide rate of 8.06.

That statewide rate and gun violence generally is steadily declining, following national trends, but the report shows that homicide persists as the leading cause of death for black youths in California. It is the second leading cause of death for young California Latinos after unintentional injuries.

Still, the improving statistics and related efforts to stop youth violence in California cities are worth noting and should set an example elsewhere, said Josh Sugarmann, executive director of the Violence Policy Center, a nonprofit organization based in Washington, D.C., that promotes gun control and examines violence as a public health problem.

“California has been battling gun violence for decades and youth violence in particular,” Sugarmann said. “What’s come out of that is a recognition that prevention and intervention works far more effectively than suppression and incarceration.”

Sugarmann said that “California is a leader as far as moving away from a ‘lock-’em-up, throw-away-the-key approach.'”

Funded by a grant from the California Wellness Foundation, his group’s report also highlights the work of Oakland-based Youth UpRising and other organizations around the state that work directly with young people in preventing violence.

Alameda County’s No. 4 youth homicide ranking in 2012 was lower than its No. 2 spot in 2010, but in sheer numbers, its 62 youth homicides — most of them in Oakland — were second only to Los Angeles County, where 207 young people were murdered in 2012.

Of the Alameda County victims, 71 percent were male and 73 percent were black. Most of the homicides happened on a street, sidewalk or in a parking lot.

Solano County ranked sixth on the list and Contra Costa ranked eighth. Ranking lower, at No. 14, was populous Santa Clara County, but rising youth homicides in and near San Jose — long considered one of the safest big U.S. cities — inched the county up from 18th in 2011 and 27th in 2010.

Many reasons are cited for the decline of youth gun violence happening throughout the country. One is that shooting victims might be more likely to survive.

During the height of America’s gun violence epidemic in the 1990s, said Sugarmann, “a large proportion of people who were shot would most likely die. That has changed with improvements in medical technology.”