Anas reported: The Messenger of Allah, peace and blessings be upon him, would say when he retired to his bed, “All praise is due to Allah who has fed us, given us drink, sufficed us, and sheltered us. How many are those who do not have enough and have no shelter?”
Source: Ṣaḥīḥ Muslim 2715
Grade: Sahih (authentic) according to Muslim
عَنْ أَنَسٍ أَنَّ رَسُولَ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ كَانَ إِذَا أَوَى إِلَى فِرَاشِهِ قَالَ الْحَمْدُ لِلَّهِ الَّذِي أَطْعَمَنَا وَسَقَانَا وَكَفَانَا وَآوَانَا فَكَمْ مِمَّنْ لَا كَافِيَ لَهُ وَلَا مُؤْوِيَ
2715 صحيح مسلم كتاب الذكر والدعاء والتوبة والاستغفار باب ما يقول عند النوم وأخذ المضجع