Overdose deaths from prescription drugs and illegal drugs such as heroin continue to rise in Maine, according to statistics released Wednesday by the state Medical Examiner’s Office.

Maine had 174 accidental overdose deaths in the first nine months of 2015, with 71 caused at least in part by heroin. Such deaths are on pace to reach 230 to 250 for the year.

Last year, Maine had 208 accidental overdose deaths, with 57 attributed to heroin.

Heroin was a factor in 41 percent of the overdose deaths this year, and 31 percent of the deaths involved fentanyl or acetyl fentanyl, a synthetic opiate that is much stronger than heroin. Pharmaceutical painkillers such as oxycodone were factors in 40 percent of the deaths.

Many overdose deaths are the result of a combination of drugs.

“Maine’s opioid epidemic continues to rage,” said Attorney General Janet Mills in a statement announcing the latest statistics. “This problem seems to have the attention of everyone but the users.

“I am heartened by the response I have seen from leaders in our state who all want to solve this problem,” she said. “In recent days the police have taken major actions to disrupt the supply of heroin and other opiates into our state and to protect our citizenry from those who would sell it. …We must also begin the long effort of curbing the demand for these deadly substances by educating people of the dangers and supporting people in recovery from addiction.”

Kenny Miller, executive director of the Down East AIDS Network and the Health Equity Alliance, said important legislation was passed last year to expand access to Narcan, which can reverse the effects of an overdose.

“Part of what’s feeding into these overdose deaths is, that law hasn’t taken affect,” he said.

Physicians can prescribe Narcan to patients who might need it, though there has been reluctance because of liability concerns, Miller said. Public health organizations also will be allowed to distribute Narcan kits to the users they interact with, but the Department of Health and Human Services is still writing the rules to cover when that is done.

Other legislative initiatives that might have helped reduce the number of overdose deaths did not pass or were watered down.

So-called good Samaritan laws protect people who call to report overdoses from prosecution. Maine passed a law allowing a person who reports an overdose to use that as a defense against prosecution, but that falls short of the ideal, Miller said.

States such as Massachusetts and Vermont do not permit the arrest of a person who reports an overdose at the scene, though police can still do a criminal investigation.

Groups that work toward harm reduction advocate that people who use heroin and similar drugs do so in the company of others, so there is someone who can call if there is an overdose. They also encourage people to do a test shot, to understand how strong the dose is. Police are finding some heroin combined with fentanyl to make it more powerful, or fentanyl substituted for heroin. Both are more dangerous than heroin alone.

Miller said the key to reducing overdose deaths is to work on prevention through education and to expand access to treatment.

“When we come across people who are ready to access treatment, we don’t have anywhere to send them,” Miller said. “We’re facing a bottleneck as far as treatment is concerned.”