A New Hampshire woman visits the grave of her fiance, who died of an overdose. Such deaths have skyrocketed in Maryland in recent years. (Jim Cole/AP)

Drug-overdose deaths surged to new levels in Maryland during the first nine months of 2016, far surpassing the total for all of the previous year as fatalities related to heroin and fentanyl use increased sharply.

The state health department reported Thursday that the number of overdose deaths for January through September climbed to 1,468, a 62 percent jump compared with the same period in 2015, and the sixth straight year that the figure has risen.

The total for the first three quarters of 2016 exceeded the overall sum for the previous year by nearly 17 percent.

Maryland health officials say the alarming trends are part of a nationwide opioid epidemic that involves growing use of heroin, prescription pain medications and fentanyl, the powerful synthetic opioid that killed rock legend Prince in April.

The state’s new health secretary, Dennis R. Schrader, urged Marylanders who are dealing with substance abuse to visit his agency’s online tool for locating treatment centers.

“To not seek help for a drug problem now is to risk death,” he said in a statement.

Fentanyl-related overdoses accounted for the most drastic increase during the first nine months of 2016, with the number jumping to 738, nearly triple from the same span last year. Such deaths have been skyrocketing for the past three years, growing more than 33-fold during that time.

State health officials say many people unwittingly buy fentanyl or fentanyl-laced drugs when they try to purchase heroin, which is several times less potent. In the first nine months of this year, there were 503 overdose deaths involving a combination of heroin and fentanyl, compared with 124 in 2015.

The number of deaths related to heroin, including combinations with other drugs, rose 72 percent to 918 during the first three quarters of 2016. The total for prescription opioids, including in combination with other sub­stances, jumped 17 percent to 270.

Baltimore had 481 fatal overdoses from January through September, the highest number of all jurisdictions in the state and a 65 percent increase compared with the same period in 2015.

Anne Arundel County ranked second with 146 deaths, or nearly double its count from the previous year; Prince George’s County was fourth with 89, a 71 percent rise; and Montgomery County was fifth with 72, a 26 percent uptick.

The growth in fatal overdoses has come despite recent efforts by the state to combat the opioid epidemic.

Gov. Larry Hogan (R), who lost a cousin to a heroin overdose, created a task force in 2015 to develop plans for addressing the problems. Based on that group’s recommendations, he released more than $2 million last year to expand access to treatment in rural parts of the state, create a Baltimore-based outreach program for overdose survivors, boost police efforts to disrupt drug trafficking, and launch a public-awareness campaign.

This year, Hogan allocated $5.3 million in new spending to support addiction treatment in prisons and to modestly increase the reimbursement rate for providers of drug-abuse treatment. He and the legislature also advanced legislation requiring all prescribers to use a statewide data­base that tracks potential abuse of pain medications, and alerts doctors, pharmacists, licensing boards and police of suspicious activity.

Additionally, the state Department of Health and Mental Hygiene authorized pharmacists last year to dispense naloxone to thousands of individuals who have been trained and certified to administer the overdose-reversal drug.

Similarly, Baltimore has issued a “blanket prescription” for naloxone, which is sold under the brand name Narcan, so that anyone in the city can obtain the lifesaving drug.

Some treatment advocates have criticized efforts to expand the use of naloxone, saying the state should focus on long-term and residential treatment options instead.

“Narcan doesn’t change the behavior of the addicts,” said Michael Gimbel, a former Baltimore County drug czar who had been a heroin addict. “If we don’t get them into treatment, most of the time they’re going to keep using.”

Baltimore Health Commissioner Leana Wen said in a statement Thursday that long-term treatment tends to be underfunded.

“Addiction is a disease . . . and must be addressed as any other chronic disease,” she said. “We must both save a life today with acute treatments, like the opioid overdose reversal medication naloxone, while also ensuring access to evidence-based treatment.”

The rise in fatal overdoses this year has extended beyond opioids. Fatal overdoses related to cocaine not mixed with other drugs jumped 76 percent to 69, while alcohol-only deaths increased more than 36 percent to 30. The figures for both years represent data from January through September.