The Family Of Imran - 3:191 "Those who remember Allah while standing, sitting and lying on their sides. They think about the structure and creation of the heavens and the earth: "Our Lord, You did not create them in vain, You are exalted, protect us from the torment of the Fire."
Related:
The Bee/16:3 He created the heavens and the earth for a purpose. He is far greater than those they associate partners with.
خَلَقَ السَّمٰوَاتِ وَالْاَرْضَ بِالْحَقِّۜ تَعَالٰى عَمَّا يُشْرِكُونَ

The Prophets/21:16 We did not create the heavens and the earth and all that is between them for play.
وَمَا خَلَقْنَا السَّمَٓاءَ وَالْاَرْضَ وَمَا بَيْنَهُمَا لَاعِب۪ينَ
The Prophets/21:17 If We had wished to have a pastime, We would have made it from Our own Presence. Yes, if We had wished such a thing!
لَوْ اَرَدْنَٓا اَنْ نَتَّخِذَ لَهْواً لَاتَّخَذْنَاهُ مِنْ لَدُنَّاۗ اِنْ كُنَّا فَاعِل۪ينَ

The Arabic Letter Sad/38:27 We did not create the heavens and the earth and all that is between them in vain; that is the delusion of those who disbelieve. Woe to those who disbelieve, for they put themselves into the Fire.
وَمَا خَلَقْنَا السَّمَٓاءَ وَالْاَرْضَ وَمَا بَيْنَهُمَا بَاطِلاًۜ ذٰلِكَ ظَنُّ الَّذ۪ينَ كَفَرُواۚ فَوَيْلٌ لِلَّذ۪ينَ كَفَرُوا مِنَ النَّارِۜ

The Smoke/44:38 We did not create the heavens and the earth and all that is between them for play and amusement.
وَمَا خَلَقْنَا السَّمٰوَاتِ وَالْاَرْضَ وَمَا بَيْنَهُمَا لَاعِب۪ينَ
The Smoke/44:39 We created them only for a purpose. But most of them do not know.
مَا خَلَقْنَاهُمَٓا اِلَّا بِالْحَقِّ وَلٰكِنَّ اَكْثَرَهُمْ لَا يَعْلَمُونَ