Sayyiduna Anas bin Maalik (radiyallahu’anhu) reports that it was the noble practice of our beloved Rasulullah (sallallahu ‘Alaihi wasallam) after every Fardh Salah to place his right hand on his forehead (and in some narrations: on his head) and recite the following supplication:
بِسْمِ اللهِ الذِيْ لا إلٰهَ إِلا هُوَ الرحْمٰنُ الرحِيم ، اللهُم أَذْهِبْ عَني الْهَم وَالحُزْن
Bismillahillazhy laa ilaaha illa huwa-Rahmaanu-Raheem. Allahumma Azh-hib ‘annil-hamma wal-huzn.
Translation: In the name of Allah, besides whom there is none worthy of worship, The most Gracious, The most Merciful.
O Allah ! remove from me worry and depression.
This narration is suitable for practice and has been recorded by the following authorities: Imams: Ibn-Sunni (rahimahullah), pg.101 (Hadith: 112), Al-Tabarani (rahimahullah) (Al-Mu’jamul-Awsat Hadith: 2520 and Kitabu-Du’a, pg.210 Hadith: 659; Majma’uz-zawaid, vol.10, pg.110) Khateeb Al-Baghdadi (rahimahullah) (Tareekh-Baghdad, vol.12 pg.480-481), Abu Nu’aim (rahimahullah) (Al-Hilyah, vol.2 pg.341-342 Hadith: 2493) and Ibn ‘Adiy (Al-Kamil, vol.7 pg.199)
Another beneficial du’a for depression is: abundant recital of
لَا حَوْلَ وَلَا قُوَّةَ إِلَّا بِالله
La hawla wala quwwata illa billah
“It is a cure for ninety nine illnesses, the lightest being: depression/anxiety”
(Hakim; Targheeb 2/444)