The Prophet ﷺ never removed his sandals during prayer except on one occasion, when the people also removed their sandals. The Prophet ﷺ asked, "Why did you remove your sandals?"They replied, "We saw you remove yours, so we removed ours."He said, "Jibreel informed me that there was filth on them."
لم يخلع النبي ﷺ نعليه في الصلاة إلا مرة، فخلع القوم نعالهم، فقال النبي ﷺ: لم خلعتم نعالكم؟ قالوا: رأيناك خلعت فخلعنا فقال: إن جبريل عليه السلام أخبرني أن بها قذرا.
Tabarani related it in al-Awsat (4305) from Abdullah bin Ahmad bin Hanbal, who said, Ibrahim bin Hajjaj Sami told me, who said, Abdullah bin Muthanna told us, who said, Thumamah told us, from Anas, who said, then he mentioned it.Bazzar related it in Kashf Astar (605) through another route from Abdullah bin Muthanna, in abbreviated form. Haythami said in Majma al-Zawaid (2260), "The men of Tabarani's chain are the men of the Sahih, and Bazzar related it in abbreviated form."I say, it is not as he said, for Ibrahim bin Hajjaj Sami, Abu Ishaq Basri, is not among the men of the Sahih. Rather, he is among the men of Nasai, though he is trustworthy. And Abdullah bin Muthanna, although he is among the men of Bukhari, was criticized for his memory, though his hadith is hasan. And Thumamah is the son of Abdullah bin Anas bin Malik Ansari, who narrated from his grandfather, and he is among the men of the two Sahihs.Bazzar said, "We do not know it from Anas except through this route."I say, it is as he said, except that it serves as a strong supporting witness for the hadith of Abu Saeed Khudri, which is the hadith that follows.