When the Messenger of Allah ﷺ passed away, his wives wanted to send Uthman bin Affan to Abu Bakr al-Siddiq to ask him for their inheritance from the Messenger of Allah ﷺ.Ayesha said to them, "Did the Messenger of Allah ﷺ not say, 'We are not inherited from. Whatever we leave behind is charity'?"
أن أزواج النبي ﷺ حين توفي رسول الله ﷺ اردن أن يبعثن عثمان بن عفان إلى أبي بكر الصديق، فيسألنه ميراثهن من رسول الله ﷺ فقالت لهن عائشة: أليس قد قال رسول الله ﷺ: لا نورث ما تركنا فهو صدقة؟
Malik related it in "Speech, Backbiting, and Purity" (27) from Ibn Shihab, from Urwa bin Zubayr, from Ayesha, and mentioned it. Bukhari also related it in "Inheritance Shares" (6730), and Muslim in "Jihad and Expeditions" (1758), both through the route of Malik with the same wording.