Xanax can worsen depression, speaking from experience, the experience of my mom and simple research. It can help with anxiety, but it very habit forming and quickly tolerated. My opinion is that xanax should always be a last resort. I took it for Generalized Anxiety disorder, my mom still takes it for full blown panic attack disorder and both of us know it may help you fall asleep but it won't necessarily help you get quality sleep. Have you tried any alternatives? I understand by the way, I have depression, anxiety, PTSD, all kinds of fun stuff! :)
Shouldn't make your depression worse, xanax is used temporally to relax people. If anything it should help you sleep and probably improve your depresion