Narrated Aisha, Ummul Mu'minin: A woman said: Messenger of Allah, my mother suddenly died; if it had not happened, she would have given sadaqah (charity) and donated (something). Will it suffice if I give sadaqah on her behalf? The Prophet ﷺ said: Yes, give sadaqah on her behalf.
Giving charity is an important part of Islam and it is something that all Muslims should strive to do as much as possible. Not only does it help those who are in need but it also brings us closer to Allah and helps us gain His blessings. By giving charity on behalf of someone who has passed away, we are showing our love for them and helping them gain rewards from Allah even after their death.