—may Allah bless him and grant him peace—would lie on his right side, and he instructed al-Barāʾ ibn ʿĀzib to do likewise. This is the optimal posture, whether the qibla is behind you, before you, to your right, or to your left; what matters is to sleep on the right side in obedience to the Prophet’s command.
Some people are accustomed to sleeping on their left side, and when they try the right side sleep may not come easily. Nevertheless, they must train themselves, for the matter is no small thing: it is firmly established by the Messenger’s own practice and by his instruction. When you lie on your right side you become conscious that you are following the Messenger—peace and blessings be upon him—who slept on his right, and that you are fulfilling his command. So discipline yourself; strive for a day or two, or even a week, until you can sleep while observing the Sunnah of your Prophet—may Allah bless him and grant him peace.
Among the Sunnahs as well—when feasible—is to place your right hand beneath your right cheek, for this too is authentically reported from the Messenger, peace be upon him. If you can manage it, it is good and preferable; if you cannot, it is certainly not on the same level of importance as sleeping on the right side.
It is also recommended to recite the invocation taught by the Prophet—peace and blessings be upon him:
“O Allah, I surrender my soul to You, I turn my face toward You, I entrust my affairs to You, and I lean upon You, in hope of You and in fear of You; there is no refuge and no deliverance…”