Doctors often prescribe this antidepressant for sleep troubles, according to Consumer Reports. But does it work—and is it safe for insomnia?

The top prescribed drugs for insomnia are pretty familiar: Ambien and Lunesta. But there’s another drug being used to help people fall asleep that’s actually a decades-old generic antidepressant. It’s called trazodone, and it has been used as a sleep drug because it can cause drowsiness as a side effect.

Research suggests that it’s now one of the most commonly prescribed medications to treat sleeplessness. Here’s why, and what to do if your doctor suggests that you try it.