Jabir bin Samura reported,

The Messenger of Allah ﷺ said, "People must stop raising their eyes to the sky during prayer, or their sight will not return to them."

Azami 2613

Sahih

عن جابر بن سمرة قال

قال رسول الله ﷺ: لينتهين أقوام يرفعون أبصارهم إلى السماء في الصلاة أو لا ترجع إليهم.

الأعظمي 2613صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Prayer
Chapter
What is prohibited and disliked in prayer
Section
Dislike of raising one's gaze to the sky during prayer
Numbering
Jami al-Kamil 2613 (2nd edition)
Azami 2613