عن أبي هريرة رضي الله عنه قال: كان النبي صلى الله عليه وسلم يعتكف في كل رمضان عشرة أيام، فلما كان العام الذي قُبِضَ فيه اعتكف عشرين يوماً.
[صحيح] - [رواه البخاري]
Abu Hurayrah (may Allah be pleased with him) reported: The Prophet (may Allah's peace and blessings be upon him) used to observe I‘tikāf during each Ramadan for ten days. The year in which he died, he observed I‘tikāf for twenty days.
Sahih/Authentic. - [Al-Bukhari]
The Prophet (may Allah's peace and blessings be upon him) used to confine himself to the mosque to worship Allah for ten days in each Ramadan, particularly the middle ten nights of the month, with the hope that he would observe Laylat al-Qadr [Night of Decree] in those days. When he knew that the Night of Decree was in the last ten nights, he confined himself during those ten nights. The year in which he died, he secluded himself for twenty days to worship Allah Almighty more, and to get even closer to Him.