وَتَأْخِيرُ الْعِشَاءِ إِلَى ثُلُثِ اللَّيْلِ، وَتَأْخِيرُ الْوِتْرِ إِلَى آخِرِ اللَّيْلِ لِمَنْ يَثِقُ بِالِانْتِبَاهِ
Delaying Isha to around the first third of the night is recommended. A person confident of waking may delay Witr toward the end of the night; one who fears not waking should pray it before sleeping.