(28) باب تَسْوِيَةِ الصُّفُوفِ وَإِقَامَتِهَا وَفَضْلِ الأَوَّلِ فَالأَوَّلِ مِنْهَا وَالاِزْدِحَامِ عَلَى الصَّفِّ الأَوَّلِ وَالْمُسَابَقَةِ إِلَيْهَا وَتَقْدِيمِ أُولِي الْفَضْلِ وَتَقْرِيبِهِمْ مِنَ الإِمَامِ
Abu Sa'id al-Khudri reported:
The Messenger of Allah (ﷺ) saw people at the end of the mosque, and then the (above-mentioned hadith) was narrated.
Reference: Sahih Muslim 438 b
In-book reference: Book 4, Hadith 145
USC-MSA web (English) reference(deprecated numbering scheme): Book 4, Hadith 879