Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:21:28

He knows what is ˹presently˺ before them and what will be after them, and they cannot intercede except on behalf of one whom He approves. And they, from fear of Him, are apprehensive.  

He knows what is before them and what is behind them, that is, what they have done and what they will do, and they do not intercede except for him with whom He is satisfied, that he be interceded for, and they, for awe of Him, exalted be He, are apprehensive, fearful.
القرآن:٢١:٢٨

يَعْلَمُ مَا بَيْنَ أَيْدِيهِمْ وَمَا خَلْفَهُمْ وَلَا يَشْفَعُونَ إِلَّا لِمَنِ ارْتَضَىٰ وَهُمْ مِنْ خَشْيَتِهِ مُشْفِقُونَ  

{يعلم ما بين أيديهم وما خلفهم} ما عملوا وما هم عاملون {ولا يشفعون إلا لمن ارتضى} تعالى أن يشفع له {وهم من خشيته} تعالى {مشفقون} خائفون.