The Messenger of Allah ﷺ used to encourage people to pray during the nights of Ramadan without commanding it as an obligation. He would say, "Whoever prays through Ramadan out of faith and seeking reward will be forgiven his previous sins."Ibn Shihab said, "The Messenger of Allah ﷺ passed away with the matter standing as it was, and it remained so through the caliphate of Abu Bakr and the early part of the caliphate of Umar bin Khattab."
و حدثني عن مالك عن ابن شهاب عن أبي سلمة بن عبد الرحمن بن عوف
أن رسول الله ﷺ كان يرغب في قيام رمضان من غير أن يأمر بعزيمة فيقول من قام رمضان إيمانا واحتسابا غفر له ما تقدم من ذنبه قال ابن شهاب فتوفي رسول الله ﷺ والأمر على ذلك ثم كان الأمر على ذلك في خلافة أبي بكر وصدرا من خلافة عمر بن الخطاب