Sahih Muslim 4157
صحيح مسلم#4157SahihAbu Huraira (Allah be pleased with him) reported that when the body of a dead person having burden of debt upon him was brought to Allah's Messenger (ﷺ) he would ask whether he had left property enough to clear off his debt, and if the property left had been sufficient for that (purpose), he observed funeral prayer for him, otherwise he said (to his companions):You observe prayer for your companion. But when Allah opened the gateways of victory for him, he said: I am nearer to the believers than themselves, so if anyone dies leaving a debt, its payment is my responsibility, and if anyone leaves a property, it goes to his heirs
Scholarly Authentication
We show the most cautious grade (weakest-wins) as the overall label. Individual scholars graded it as follows:
Every narration in Sahih Muslim is accepted as Sahih (authentic) by the established status of the book.
In-book reference: 23:18