Riyad as-SalihinChapter 17Hadith 1072
Full Sharh — Riyad as-Salihin 1072
عن أبي هريرة رضي الله عنه أن النبي صلى الله عليه وسلم قال: "أما يخشى أحدكم إذا رفع رأسه قبل الإمام أن يجعل الله رأسه رأس حمار! أو يجعل الله صورته صورة حمار" ((متفق عليه)).
English Translation
Abu Hurairah (May Allah be pleased with him) said:: The Prophet (ﷺ) said, "Does he who raises up his head before the Imam not fear that Allah will make his head that of a donkey or make his appearance similar to that of donkey?".
Source
Riyad as-Salihin(رياض الصالحين)
The Book of the Prohibited actions
Hadith Number
1072