(10) بَابُ: {وَيُؤْثِرُونَ عَلَى أَنْفُسِهِمْ وَلَوْ كَانَ بِهِمْ خَصَاصَةٌ}
Narrated Abu Huraira:
A man came to the Prophet. The Prophet (ﷺ) sent a messenger to his wives (to bring something for that man to eat) but they said that they had nothing except water. Then Allah's Messenger (ﷺ) said, "Who will take this (person) or entertain him as a guest?" An Ansar man said, "I." So he took him to his wife and said to her, "Entertain generously the guest of Allah's Messenger (ﷺ) " She said, "We have got nothing except the meals of my children." He said, "Prepare your meal, light your lamp and let your children sleep if they ask for supper." So she prepared her meal, lighted her lamp and made her children sleep, and then stood up pretending to mend her lamp, but she put it off. Then both of them pretended to be eating, but they really went to bed hungry. In the morning the Ansari went to Allah's Messenger (ﷺ) who said, "Tonight Allah laughed or wondered at your action." Then Allah revealed: "But give them (emigrants) preference over themselves even though they were in need of that And whosoever is saved from the covetousness Such are they who will be successful." (59.9)
Reference: Sahih al-Bukhari 3798
In-book reference: Book 63, Hadith 24
USC-MSA web (English) reference(deprecated numbering scheme): Vol. 5, Book 58, Hadith 142