It is narrated from Sayyiduna Abu Hurayrah (may Allah be pleased with him) that the Prophet (peace and blessings be upon him) came for the prayer; when the takbir was said, he went back and gestured to the Companions (may Allah be pleased with them): "Remain as you are." Then he (peace and blessings be upon him) came out of his house with drops of water falling from his (peace and blessings be upon him) head. He (peace and blessings be upon him) led the Companions (may Allah be pleased with them) in prayer. When he finished the prayer, he said: "I was in a state of major ritual impurity (janabah) and forgot to take the ritual bath (ghusl)."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 4066