I asked Allah's Messenger (ﷺ) about looking hither and thither in prayer. He replied, "It…

Sahih al-Bukhari Book 10 Hadith 145

Sahih al-Bukhari #751

Call to Prayers (Adhaan) 10:145

Narrated `Aisha:

I asked Allah's Messenger (ﷺ) about looking hither and thither in prayer. He replied, "It is a way of stealing by which Satan takes away (a portion) from the prayer of a person."

Chapter: To look hither and thither in As-Salat (the prayer)

Grade: Sahih