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:9:81

Those who remained behind rejoiced in their staying ˹at home˺ after ˹the departure of˺ the Messenger of Allah and disliked to strive with their wealth and their lives in the cause of Allah and said, "Do not go forth in the heat." Say, "The fire of Hell is more intensive in heat" - if they would but understand.  

Those who were left behind, from ˹the journey to˺ Tabūk, rejoiced at remaining behind the Messenger of God, and were averse to striving with their wealth and their lives in the way of God. And they said, that is, they said to one another, ‘Do not go forth, do not set off to ˹join˺ the fight, in the heat!’ Say: ‘The fire of Hell is hotter, than Tabūk, and more worthy for them to guard against, by not staying behind, did they but understand’, this, they would not have stayed behind.
القرآن:٩:٨١

فَرِحَ الْمُخَلَّفُونَ بِمَقْعَدِهِمْ خِلَافَ رَسُولِ اللَّهِ وَكَرِهُوا أَنْ يُجَاهِدُوا بِأَمْوَالِهِمْ وَأَنْفُسِهِمْ فِي سَبِيلِ اللَّهِ وَقَالُوا لَا تَنْفِرُوا فِي الْحَرِّ ۗ قُلْ نَارُ جَهَنَّمَ أَشَدُّ حَرًّا ۚ لَوْ كَانُوا يَفْقَهُونَ  

{فرح المخلَّفون} عن تبوك {بمقعدهم} أي بقعودهم {خلاف} أي بعد {رسول الله وكرهوا أن يجاهدوا بأموالهم وأنفسهم في سبيل الله وقالوا} أي قال بعضهم لبعض {لا تنفروا} تخرجوا إلى الجهاد {في الحر قل نار جهنم أشدُّ حرا} من تبوك فالأولى أن يتقوها بترك التخلف {لو كانوا يفقهون} يعلمون ذلك ما تخلفوا.