May Allah bless you and your family.
Yes, we have a ḥadīth in that vein:
یَا ابا ذر! کُنْ کَأَنَّکَ فِی الدُّنْیَا غَرِیبٌ أَوْ کَعَابِرِ سَبِیلٍ، وَ عُدَّ نَفْسَکَ مِنْ أَصْحَابِ الْقُبُورِ
“Abū Dharr! Be like a stranger in this temporary life or like you are a mere traveler. And consider yourself like one of the people of the graves.”
This phrase is part of a longer ḥadīth found in Makārim al-Akhlāq of al-Ḥasan ibn Faḍl al-Ṭabarsī, the son of the author of the tafsīr entitled Majmaʿ al-Bayān. You can read a translation of the ḥadīth here: https://www.al-islam.org/articles/advice-prophet-s-gave-abu-dharr
The phrase “count yourself like one of the people of the graves” means to live as if death is imminent—or, more directly, act as if you are about to die. In other words, live a pious life because you don’t know when you are going to die and return to your Creator and be held accountable for your misconduct. Never take a day or even a moment for granted and expect that if you sin, you will have a moment after the sin to repent. Act as if, at any moment, you may be lowered into your grave and have no second chance to live a pious life.
One way to encourage this line of thinking is to visit a Muslim graveyard or the graves of deceased family members and contemplate how close death is and how close the afterlife is—how short our lives are. This should encourage us to, at bare minimum, complete our obligations (wājibāt) and refrain from all that is prohibited (muḥarramāt).