Abdullah bin Umar reported,

Umar رضي الله عنه had vowed during the days of ignorance to perform itikaf in the Sacred Mosque. The narrator said, "I think he said, for one night." The Messenger of Allah ﷺ said to him, "Fulfill your vow."

Bukhari 2043

Sahih

حدثنا عبيد بن إسماعيل حدثنا أبو أسامة عن عبيد الله عن نافع

عن ابن عمر

أن عمر رضي الله عنه نذر في الجاهلية أن يعتكف في المسجد الحرام قال أراه قال ليلة قال له رسول الله ﷺ أوف بنذرك

البخاري 2043صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Itikaf
Chapter
If one vowed during the Jahiliyyah to perform itikaf, then became Muslim
Numbering
Darussalam 2043
Bukhari 2043