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.
bayhaqi:9767Abū Saʿīd b. Abū ʿAmr > Abū al-ʿAbbās al-Aṣam > al-Rabīʿ b. Sulaymān > al-Shāfiʿī > Uḥib Lah Idhā And Ddaʿ al-Bayt

[Machine] To stand in between the corner and the door, saying: "O Allah, the House is Your House, and the servant is Your servant, and the son of Your servant, and the son of Your maidservant. You have carried me on what You have made available for me from among Your creation, and You have guided me in Your land and made me reach Your blessings, until You have enabled me to fulfill Your rituals. So, if You are pleased with me, then increase me in satisfaction. And if not, then even now, before You leave Your home, my abode, this is the time for my departure, if You allow me. I am not asking for a substitute for You or Your House, nor am I seeking separation from You or Your House. O Allah, accompany me with well-being in my body, protection in my religion, and improve my fate. And provide me with Your obedience for as long as You keep me alive. These are the words of Al-Shafi'i, may Allah have mercy on him, and they are good."  

البيهقي:٩٧٦٧أَخْبَرَنَا أَبُو سَعِيدِ بْنُ أَبِي عَمْرٍو ثنا أَبُو الْعَبَّاسِ الْأَصَمُّ أنبأ الرَّبِيعُ بْنُ سُلَيْمَانَ أنبأ الشَّافِعِيُّ قَالَ أُحِبُّ لَهُ إِذَا وَدَّعَ الْبَيْتَ

أَنْ يَقِفَ فِي الْمُلْتَزَمِ وَهُوَ بَيْنَ الرُّكْنِ وَالْبَابِ فَيَقُولُ اللهُمَّ الْبَيْتُ بَيْتُكَ وَالْعَبْدُ عَبْدُكَ وَابْنُ عَبْدِكَ وَابْنُ أَمَتِكَ حَمَلْتَنِي عَلَى مَا سَخَّرْتَ لِي مِنْ خَلْقِكَ حَتَّى سَيَّرْتَنِي فِي بِلَادِكَ وَبَلَّغْتَنِي بِنِعْمَتِكَ حَتَّى أَعَنْتَنِي عَلَى قَضَاءِ مَنَاسِكِكَ فَإِنْ كُنْتَ رَضِيتَ عَنِّي فَازْدَدْ عَنِّي رِضًا وَإِلَّا فَمِنَ الْآنِ قَبْلَ أَنْ تَنْأَى عَنْ بَيْتِكَ دَارِي فَهَذَا أَوَانُ انْصِرَافِي إِنْ أَذِنْتَ لِي غَيْرَ مُسْتَبْدِلٍ بِكَ وَلَا بِبَيْتِكَ وَلَا رَاغِبًا عَنْكَ وَلَا عَنْ بَيْتِكَ اللهُمَّ فَاصْحَبْنِي بِالْعَافِيَةِ فِي بَدَنِي وَالْعِصْمَةِ فِي دِينِي وَأَحْسِنْ مُنْقَلَبِي وَارْزُقْنِي طَاعَتَكَ مَا أَبْقَيْتَنِي وَهَذَا مِنْ قَوْلِ الشَّافِعِيِّ رَحِمَهُ اللهُ وَهُوَ حَسَنٌ