Sayyiduna Ibn Abbas (may Allah be pleased with them both) said: The Messenger of Allah (peace and blessings be upon him) led us in prayer and took off his sandals, so we took off our sandals too. When he had finished the prayer, he said: "Why did you take off your sandals?" We said: We saw you take them off, so we took ours off. He (peace and blessings be upon him) said: "I perceived some wetness in them."
Hadith Referenceالمعجم الكبير للطبراني / باب العين / 12045