Sayyiduna Rabi'ah bin Ka'b (may Allah be pleased with him) narrates: I used to serve the Prophet (peace and blessings be upon him) during the day, and at night I would come to the door of the Prophet (peace and blessings be upon him) and spend the night there. I would keep hearing him recite: "Subhan Allah, Subhan Allah, Subhana Rabbi (Glory be to Allah, Glory be to Allah, Glory be to my Lord)," until I grew tired, or (the narrator is unsure, perhaps the words are:) my eyes would overcome me and I would fall asleep. One day the Prophet (peace and blessings be upon him) said: "O Rabi'ah! Ask of me and I will give you." I said: "Give me some time so that I may think it over." I reflected that this world is perishing and will come to an end, so I said: "O Messenger of Allah! I ask you to supplicate to Allah Almighty to save me from Hell and admit me into Paradise." the Prophet (peace and blessings be upon him) remained silent, then he (peace and blessings be upon him) asked: "Who told you to ask this?" I said: "No one told me to, but I know that this world will come to an end and perish, and you hold the station you hold with Allah Almighty, so I wished that you would supplicate to Allah Almighty." the Prophet (peace and blessings be upon him) said: "I will do so; help me (in this) by performing many prostrations."
(Allamah al-Haythami says:) I say: Part of it is recorded in the Sahih.
Al-Tabarani recorded it in al-Mu'jam al-Kabir; its chain contains Ibn Ishaq, who is thiqah (trustworthy) but a mudallis (one who conceals defects in the chain).