It is stated in a hadith that
لَا حَوْلَ وَلَا قُوَّةَ إِلَّا بِاللَّهِ
is the medicine for 99 ailments, the least of which is depression.

(Baihaqi in Dawatul Kubra)
It means that these words are so beneficial and useful that big/great grievances, depression and sorrow are easily removed in its stride.
Abdullah bin Abbas (R.A.) narrates that Prophet Mohammad (S.A.W.) stated that if a person constantly makes "Astaghfar", then Allah removes every difficulty, frees him from every sorrow and makes a means for him to receive sustencance from places that he never thought of.