There have been studies done on this topic, and they tend to demonstrate that it really does vary from person to person.
For some people, religion can be a good support system, and it can provide feelings of self-transcendence.
However, religion also often carries heavy connotations of abusive power and control, both from clerics/monks who demand obedience and fellow members who use social pressures to enforce conformity.
This is particularly nasty in the case of, for instance, queer evangelical Christians, who usually suffer specifically because of their religions, to say nothing of "Catholic guilt."
In my opinion, it's playing with fire. You're better off relying on secular therapies and psychiatric treatments, because they have a much higher efficacy rate and lower risk.