Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:39:20

But those who have feared their Lord - for them are chambers, above them chambers built high, beneath which rivers flow. ˹This is˺ the promise of Allah. Allah does not fail in ˹His˺ promise.  

But as for those who fear their Lord, and therefore obey Him — for them there will be lofty abodes with ˹other˺ lofty abodes built above them, with rivers flowing beneath them, that is, beneath ˹both˺ the upper and the lower abodes — a promise of God (wa‘da’Llāhi, in the accusative because of an implied verb governing it). God does not fail the tryst, ˹He does not break˺ His promise.
القرآن:٣٩:٢٠

لَٰكِنِ الَّذِينَ اتَّقَوْا رَبَّهُمْ لَهُمْ غُرَفٌ مِنْ فَوْقِهَا غُرَفٌ مَبْنِيَّةٌ تَجْرِي مِنْ تَحْتِهَا الْأَنْهَارُ ۖ وَعْدَ اللَّهِ ۖ لَا يُخْلِفُ اللَّهُ الْمِيعَادَ  

{لكن الذين اتقوْا ربهم} بأن أطاعوه {لهم غرف من فوقها غرف مبنية تجري من تحتها الأنهار} أي من تحت الغرف الفوقانية والتحتانية {وعد الله} منصوب بفعله المقَّدر {لا يخلف الله الميعاد} وعده.

See similar narrations below:

Collected by Qurʾān
quran:3:198

But those who feared their Lord will have gardens beneath which rivers flow, abiding eternally therein, as accommodation from Allah. And that which is with Allah is best for the righteous.  

But those who fear their Lord — for them shall be Gardens underneath which rivers flow, abiding, that is, it is decreed for them to abide, therein; a hospitality (nuzul is what is prepared for a guest; it is in the accusative ˹nuzulan˺ because it is a circumstantial qualifier referring to jannāt, ‘gardens’, and its operator is the import of the adverbial phrase) from God Himself. That which is with God, in the way of reward, is better for the pious, than the enjoyment of this world.
القرآن:٣:١٩٨

لَٰكِنِ الَّذِينَ اتَّقَوْا رَبَّهُمْ لَهُمْ جَنَّاتٌ تَجْرِي مِنْ تَحْتِهَا الْأَنْهَارُ خَالِدِينَ فِيهَا نُزُلًا مِنْ عِنْدِ اللَّهِ ۗ وَمَا عِنْدَ اللَّهِ خَيْرٌ لِلْأَبْرَارِ  

{لكن الذين اتقوا ربَّهم لهم جنات تجري من تحتها الأنهار خالدين} أي مقدرين بالخلود {فيها نُزُلا} وهو ما يعد للضيف ونصبه على الحال من جَنَّاتٍ والعامل فيها معنى الظرف {من عند الله وما عند الله} من الثواب {خير للأبرار} من متاع الدنيا.