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:16:45

Then, do those who have planned evil deeds feel secure that Allah will not cause the earth to swallow them or that the punishment will not come upon them from where they do not perceive?  

Do they feel secure, those who have schemed evil, schemes against the Prophet (s) at the Council Assembly, ˹schemes˺ such as detaining him, killing him or banishing him, as mentioned in ˹sūrat˺ al-Anfāl ˹Q. 8:30˺, that God will not cause the earth to swallow them, as ˹God did˺ with Qārūn ˹Q. 28:81˺, or that the chastisement will not come upon them whence they are not aware of?, that is, in a way which would not occur to them. Indeed, they were destroyed at Badr even though they had never anticipated it.
القرآن:١٦:٤٥

أَفَأَمِنَ الَّذِينَ مَكَرُوا السَّيِّئَاتِ أَنْ يَخْسِفَ اللَّهُ بِهِمُ الْأَرْضَ أَوْ يَأْتِيَهُمُ الْعَذَابُ مِنْ حَيْثُ لَا يَشْعُرُونَ  

{أفأمِنَ الذين مكروا} المكرات {السيئات} بالنبي ﷺ في دار الندوة من تقييده أو قتله أو إخراجه كما ذكر في الأنفال {أن يخسف الله بهم الأرض} كقارون {أو يأتيهم العذاب من حيث لا يشعرون} أي جهة لا تخطر ببالهم وقد أهلكوا ببدر ولم يكونوا يقدّرون ذلك.