The Book of Oaths (Kitab Al-Aiman)

Muslim :: Book 15 : Hadith 4072

Ibn 'Umar reported that Umar (b. Khattab) said: Messenger of Allah, I had taken a vow during the days of Ignorance (Jahiliyya) that I would observe I'tikaf for a night in the Sacred Mosque. He (the Holy Prophet) said: Fulfil your vow.

Source materials are from the University of Southern California MSA site
Hadith eBooks converted from Imaan Star