Abu Rafi’ (the freed slave of the Messenger of Allah, peace be upon him) said: The Messenger of Allah, peace be upon him, saw me prostrating while my hair was tied in a knot, so he untied it.
Hadith Referenceسنن دارمي / من كتاب الصللاة / 1418
Hadith Takhrijاس روایت کی سند صحیح ہے، لیکن اس لفظ سے صرف امام دارمی رحمہ اللہ نے ذکر کیا ہے، دوسری کتب میں دوسرے سیاق سے ہے۔ دیکھئے: [أبوداؤد 646] ، [ترمذي 384] ، [ابن حبان 2279] ، [موارد الظمآن 474]
Brief Explanation
(Explanation of Hadith 1417) «عقص عقصا» refers to braiding, plaiting, or tying the hair into a bun. In light of this hadith, the scholars have considered it disliked (makruh) for men to perform prayer (salah) with their hair tied in a bun, as this resembles the practice of women. And Allah knows best.