According to a new study, the use of prescription narcotic painkillers is common during pregnancy but it can increase the likelihood that a baby will be born early or small, or the baby could go through potentially painful withdrawal symptoms after birth.

The painkillers, known as opioids, include drugs such as hydrocodone (Vicodin), oxycodone (Oxycontin), codeine and morphine. In a study of Tennessee mothers to be, researchers found that almost 30 percent used these drugs at least once, and the associated risks went up if they also smoked while pregnant.

"I was surprised by the number of women prescribed opioid pain relievers in pregnancy," said lead author Dr. Stephen Patrick, a neonatologist and assistant professor of pediatrics at Vanderbilt University in Nashville. "I was also surprised by how commonly women smoked in pregnancy, and how much that increased the risk of neonatal abstinence syndrome among those who also used opioid pain relievers in pregnancy."

Prescription painkiller use and abuse has surged in the last few years in the United States raising concern on the potential effects on newborns. Past research has shown that prescription painkiller use during pregnancy has doubled over the last 15 years.

For the new study, researchers analyzed the medical records of more than 112,000 women on the Tennessee Medicaid program between 2009 and 2011. Of these women, about 28 percent filled a prescription for at least one painkiller.

"Some women need to take opioids in pregnancy to improve their infant's outcome," Patrick said. "For women with opioid dependency, we know that use of maintenance opioids like methadone decrease rates of preterm birth compared to heroin. For these women, neonatal abstinence syndrome may occur in their infants, but it is much better than the alternative, which is preterm birth."

Forty-two percent of the women prescribed narcotics smoked during pregnancy compared to 26 percent of the women not prescribed painkillers. The research also found that the more cigarettes the women smoked daily, the more likely she was to give birth to a baby in withdrawal.

"That's a modifiable behavior," Patrick said. "For women who are in maintenance treatment, dose didn't change the risk of neonatal abstinence syndrome, but smoking mattered a lot. So you can modify your infant's risk of drug withdrawal if you decrease the amount you smoke."

"This is a really sobering article that shows the dangers of opioid prescription use during pregnancy," said Dr. Jennifer Wu, an obstetrician-gynecologist at Lenox Hill Hospital in New York City. "With this increase in prescription painkiller use, we're seeing an effect in our newborn population. If you think about how vulnerable our newborns are, this is really frightening."

Prescriptions for narcotic painkillers quadrupled between 2000 and 2009, and during this time the number of babies born with neonatal abstinence syndrome tripled, the authors said.

"Premature babies often have developmental delays and neurological problems, so anything you can do to reduce rates of prematurity, including avoiding opioids during pregnancy, you should," Wu said.

The authors calculated that for every $1 spent on short-acting prescription painkillers, there were $52 in hospital charges for newborn withdrawal.