U.S. drug regulators added a strict new warning about prescription sleeping pills like Lunesta and Ambien after well-publicized, sometimes joked-about side effects were found to sometimes lead to tragic injuries or even deaths.

The Food and Drug Administration said it had found 66 examples of patients who took the drugs and engaged in dangerous activities such as sleepwalking or driving while not fully awake, including 20 deaths linked to carbon monoxide poisoning, drowning, fatal falls, hypothermia, car crashes and apparent suicide.

There were 46 reports of serious injuries that weren’t deadly, including overdoses, burns, loss of limbs from extreme cold and self-injuries from gunshot wounds.

“These incidents can occur after the first dose of these sleep medicines or after a longer period of treatment, and can occur in patients without any history of these behaviors and even at the lowest recommended doses,” FDA acting commissioner Norman “Ned” Sharpless said in a statement. “While these incidents are rare, they are serious and it’s important that patients and health-care professionals are aware of the risk.”

The drugs, which are available as low-cost generic versions of the brand-name products, will now come with what’s known as a boxed warning — the most severe type of cautionary message that the FDA has. In addition to the warning for all patients, the FDA said that people shouldn’t take the drugs if they’ve experienced previous episodes of odd sleep behavior after taking them.

The cases are an example of how previously unknown serious side effects can emerge for medicines that have been on the market for years and used by millions of people. The FDA tracks side effects through a voluntary reporting system, investigating cases when possible problems arise.

The new warnings apply to Lunesta, which is owned by Sumitomo Dainippon Pharma and sold as a generic as eszopiclone; Pfizer’s Sonata, also sold as zaleplon; and Sanofi’s Ambien and Ambien CR, known chemically as zolpidem. The warning also applies to the drugs Edluar, Intermezzo and Zolpimist. Sumitomo Dainippon, Pfizer and Sanofi didn’t immediately return phone calls and emails seeking comment.

— Bloomberg News