After Allah commanded that He be appreciated, He ordained patience and prayer. It is a fact that the servant is either enjoying a bounty that he should be thankful for, or suffering a calamity that he should meet with patience. A Hadith states:
«عَجَبًا لِلْمُؤْمِنِ لَا يَقْضِي اللهُ لَهُ قَضَاءً إلَّا كَانَ خَيْرًا لَهُ: إِنْ أَصَابَتْهُ سَرَّاءُ فَشَكَرَ كَانَ خَيْرًا لَهُ وإنْ أَصَابَتْهُ ضَرَّاءُ فَصَبَرَ كَانَ خَيْرًا لَه»
(Amazing is the believer, for whatever Allah decrees for him, it is better for him! If he is tested with a bounty, he is grateful for it and this is better for him; and if he is afflicted with a hardship, he is patient with it and this is better for him.)
Allah has stated that the best tools to help ease the effects of the afflictions are patience and prayer. Earlier we mentioned Allah's statement:
﴿وَاسْتَعِينُواْ بِالصَّبْرِ وَالصَّلَوةِ وَإِنَّهَا لَكَبِيرَةٌ إِلاَّ عَلَى الْخَـشِعِينَ ﴾
(And seek help in patience and As-Salah (the prayer) and truly, it is extremely heavy and hard except for Al-Khashi`in ﴿i.e., the true believers in Allah﴾) (2:45)
There are several types of Sabr ـ patience: one for avoiding the prohibitions and sins, one for acts of worship and obedience. The second type carries more rewards than the first type. There is a third type of patience required in the face of the afflictions and hardships, which is mandatory, like repentance.
`Abdur-Rahman bin Zayd bin Aslam said, "Sabr has two parts: patience for the sake of Allah concerning what He is pleased with (i.e., acts of worship and obedience), even if it is hard on the heart and the body, and patience when avoiding what He dislikes, even if it is desired. Those who acquire these qualities will be among the patient persons whom Allah shall greet (when they meet Him in the Hereafter; refer to Surat Al-Ahzab 33:44), Allah willing.''