Abu Hurairah (May Allah be pleased with him) reported:
The Prophet (ﷺ) used to observe I'tikaf every year (during Ramadan) for ten days; in the year in which he passed away, he observed I'tikaf for twenty days.[Al-Bukhari].
App reference: Book 10, Hadith 3
Arabic/English book reference: Book 10, Hadith 1270