Ibn 'Abbas (RA) reported Allah's Messenger (ﷺ) as saying: Give the shares to those who are entitled to them, and what is left from those who are entitled to it goes to the nearest male heir.
Hadith ReferenceSahih Muslim / The Book of the Rules of Inheritance / Hadith: 1615