The truth is that a lot of mental illness comes from lack of money.
Its for sure a contributing factor. If you dont have good solid finances you dont feel settled in life. I have always found therapist or counselling helpful at all times. You also need to consider being physically fit and eat a decent diet + no alcohol/drugs. Its a challenge.