The number of children being hospitalized because of prescription opioid poisoning has risen sharply since 1997, especially among toddlers and older teenagers, researchers from Yale School of Medicine report.

The study, published Monday in JAMA Pediatrics, analyzed data from the Kids’ Inpatient Database, a national database of pediatric hospitalizations. Looking at data gathered every three years from 1997 through 2012, they identified 13,052 instances in which children and teens ages 1 to 19 had been hospitalized for prescription opioid poisonings; 176 of them had died.

Children ages 1 to 4 were primarily hospitalized for accidentally ingesting opioids, while the majority of teens older than 15 took the drugs with the intent to commit suicide, said Julie R. Gaither, the study’s lead author and an epidemiologist and postdoctoral fellow at Yale. She said other teenagers probably overdosed when taking the drugs for recreational purposes. She attributed the increase in poisonings among toddlers to parents or other adults within the household leaving pills within easy reach of young children.

Gaither said poisonings attributed to prescription opioids are now the leading cause of “injury-related mortality” in the United States, largely because of the wider use of the drugs in households nationwide. In 2012, doctors wrote 259 million prescriptions for opioid painkillers.

“The medical community needs to develop a safety plan for parents to store the pills and make their homes safe for their children,” Gaither said. “Physicians prescribing medications to an adult, or even a teen, need to ask if there are younger kids in the household and, if so, to make sure they know how potent the drugs are and to keep them out of reach of kids.”

Gaither said the pills should be more securely packaged and better labeled.