The Prophet (ﷺ) as saying: If anyone dies when some fast due from him has been unfulfilled, his heir must fast on his behalf.
Sunan Abi Dawud Book 22, Hadith 70