The Prophet ﷺ said, "People must stop raising their eyes toward the sky during prayer, or their sight will not return to them."
حدثنا محمد بن بشار حدثنا عبد الرحمن حدثنا سفيان عن الأعمش عن المسيب بن رافع عن تميم بن طرفة
أن النبي ﷺ قال لينتهين أقوام يرفعون أبصارهم إلى السماء أو لا ترجع أبصارهم
Muslim reported it in Sahih Muslim, the book of Prayer, the chapter on the prohibition of raising the eyes to the sky during prayer, hadith no. 428, from the hadith of Amash through this same chain.