The Messenger of Allah ﷺ would glance to his right and to his left during the prayer without turning his neck to look behind his back.
حدثنا محمود بن غيلان وغير واحد قالوا حدثنا الفضل بن موسى عن عبد الله بن سعيد بن أبي هند عن ثور بن زيد عن عكرمة
أن رسول الله ﷺ كان يلحظ في الصلاة يمينا وشمالا ولا يلوي عنقه خلف ظهره
[Its isnad is hasan] Nasai narrated it, 9/3, h: 1202 (Sahw, chapter on the permission regarding turning during prayer to the right and left), from the hadith of Fadl bin Musa, through him. Ibn Khuzayma graded it sahih, h: 485, 871, as did Ibn Hibban (Al-Ihsan): 2285. Hakim narrated it, 12/236, 237, 256, saying it meets the standard of Bukhari, and Dhahabi agreed with him.