Kriyat Shema Al HaMitah
Order of the Kriyat Shema Al HaMitah
- When saying Krias Shema Al HaMita, preferably one should say all three paragraphs of Shema, but at least one should say the first paragraph of the Shema and then say Birchat Hamapil. If one feels that one will fall asleep saying Shema in which case say Birchat Hamapil earlier and then Shema. The Sephardic minhag is to say Birchat Hamapil before Shema.
- It isn't considered an interruption between Hamapil and going to sleep to recite the paragraph of Yoshev BeSeter Elyon because its purpose is to protect oneself while sleeping.
- If one didn’t repeat Shema after Tzet HaKochavim one must say all three paragraphs and should have the proper intent to fulfill one’s obligation. 
- If you are sick you don’t need to say the whole order of Kriyat Shema Al Hamita; it is enough just to say the first paragraph of shema and the bracha of Hamapil. 
- You only need to say Kriyat Shema Al Hamita and the bracha of Hamapil once a night, so if you fall asleep and then wake up and you want to go back to bed you don’t need to repeat Hamapil. If you know that you're going to wake up for some time and go back to sleep again, you should have in mind that your bracha should exempt the second period of sleep as well.
- Birchat HaMapil should be made when one is going to sleep (one doesn’t need to wait until sleep over takes oneself) 
- Sephardim, according to many poskim, shouldn’t say the Bracha of HaMapil with Shem UMalchut if they go to sleep after Chatzot (midnight by halachic hours).  Others hold that it can be said all night. Syrians have the tradition not to say it with shem umalchut at all.
- A person can recite hamapil if he goes to sleep at any point during the night even after midnight as long as it is before Olot Hashachar. However, if a person is going to sleep right before Olot Hashachar and he is concerned that he won’t fall asleep until after Olot one shouldn’t recite Hamapil.
- If a person is going to sleep before sunset even if he is going to continue to sleep through the night he should not recite Hamapil.
- If a person is on a night flight and plans on sleeping on the plane he should recite Hamapil since his chair is like a bed for that time. However, if one doesn’t plan to go to sleep and only accidentally dozed off he doesn’t need to recite Hamapil.
Not speaking after Kriyat Shema Al HaMitah
- Once you have said קריאת שמע על המטה you shouldn’t speak, eat, or drink. Before one said the Bracha of HaMapil, if one needs to eat, drink, or say something really important there is a possibility to be lenient, and one should repeat Shema. However, if one already said the Bracha of HaMapil one shouldn’t make any interruption unless there’s a serious need. 
- Someone who wants to say the Bracha before leaving the Bet Midrash and not to say it in the room not to be bothered one may do so (but afterwards one shouldn’t make any interruptions besides going to the room and going to sleep). 
- If after one already said Birkat HaMapil one's parent asks one something and one has to answer, then it is permitted to ask because of Kibbud Av VeEm.
- Even though one should strive to say birkat hamapil as close to falling asleep as possible, if one goes to the bathroom after having said Birkat Hamapil he should still recite asher yatzar. 
- If a person said Hamapil and forgot that he didn't count sefirat haomer he can get out of bed and count. The same is true of if he forgot to daven maariv or say kiddush levana.
Position to say the Bedtime Shema
- It's good to read the Bedtime Shema sitting or standing. If you already laid down, you don’t need to get up rather say it on your side, but it is forbidden to say it while lying on your back or on your belly, after the fact one fulfills one's obligation in any position. 
If one didn't fall asleep
- Even if one didn’t end up falling asleep the Bracha is not considered in vain because the Bracha was said about people in the world going to sleep but was established for when one tried going to sleep. 
Something to Think about Before Falling Asleep
- One should have intention that one is going to sleep in order to get energy to serve Hashem with energy tomorrow.  According to some, one should verbalize this intention. 
- Before a person goes to bed it's good to consider all the things he did that day and if he finds that he did a sin he should accept upon himself not to do it again. Also it's good to forgive anyone who might have sinned against oneself.  If a person can't bring himself to forgive someone who wronged him he should skip the הרי אני מוחל וסולח that says he forgives everyone until the day he is able to forgive them.
- It is a good idea to review words of Torah while one is going to sleep.
Text of Kriyat Shema Al HaMitah
- Ashkenazic text of Kriyat Shema Al Hamita (from wikisource.com)
- Sephardic text of Kriyat Shema Al Hamita (from fxp.co.il)
- Mishna Brurah 239:1
- Shulchan Aruch 239:1 writes that one should first say Shema and then say the bracha of Hamapil in order to recite Hamapil as close to going to sleep as possible. Mishna Brurah 239:2 writes that if one feels that one will fall asleep while saying Shema one should say Hamapil first.
- Yalkut Yosef (Brachot pg 667)
- Mishna Brurah 239:2
- Mishna Brurah 239:1
- Mishna Brurah 239:9
- Rabbi Zilber in Beyt Baruch 35:9
- Mishna Brurah 239:3
- Rav Ovadia Yosef in Yachava Daat 4:21 wrote that one should say hamapil after chatzot without shem umalchut and before chatzot with shem umalchut. This is also the opinion of Yalkut Yosef (Brachot pg 664) and Or Letzion 2:15:12.
- Halacha Brurah 239:9 quoting his father Rav Ovadia Yosef that he retracted that one should say it even initially after chatzot. See Rav Ovadia's formulation in Chazon Ovadia (Brachot p. 511). See also Orchot Maran 2:19:10 p. 834 where he writes that Rav Ovadia Yosef's personal practice changed in 5771 to say hamapil after chatzot with shem umalchut. Rav Yitzchak Yosef Motzei Shabbat Emor 5778 min 18 said that his father's opinion changed on the matter and therefore one should recite the bracha of hamapil with shem umalchut even after chatzot.
- Rabbi Mansour on dailyhalacha.com explained that the Syrian minhag was to say hamapil without shem umalchut in accordance with the Ben Ish Chai (Pekudei no. 12).
- Biur Halacha 239:1 s.v. samuch, Halacha Berurah 239:9
- Betzel Chachma 5:166:9 writes that since the bracha is established only for sleep at night even though one is going to later sleep during the night the bracha needs to recited at the time that the action that obligates the bracha is performed. This is cited by Dirshu 239:7.
- Beer Moshe 7:114:3
- Piskei Teshuvot 239:3. Mishna Brurah 239:4 says that it is מותר to speak if it is important, but once you said המפיל it is a הפסק between the ברכה and the sleeping. The רמ"א says that you shouldn’t speak rather one should go to bed right after Kriyat Shema Al HaMitah. This is also the opinion of the Yalkut Yosef (Brachot pg 664, 239:1) and Halacha Brurah 239:8. Yalkut Yosef writes that it is permitted to do something necessary after hamapil such as put a child back to sleep.
- Halichot Shlomo (Tefilla pg 170)
- Yalkut Yosef (vol 3, 665)
- Sh"t Yechave Daat 4:21, Sh"t Tzitz Eliezer 7:27, and Sh"t Bear Moshe 1:63 all hold that you still should say asher yatzar, or even Kiddush Levana or arvit if necessary. Halacha Brurah 239:8 agrees.
- The Chavot Yair in Mekor Chaim 239:1 Kitzur Halachot writes that if a person forgot to count sefira, daven maariv, or say kiddush levana before saying hamapil he can do so afterwards. Rav Yitzchak Yosef (Motzei Shabbat 5778 min 1-20) explained that Rav Steinemann is quoted as saying that a person who said hamapil and forgot to count sefira should ask someone to wake them up after a half hour so that they won't make an interruption between the hamapil and sleeping and they can count when they get up. Rav Yosef argued that it was an unnecessary chumra since it is very annoying to go to sleep for only a half hour and wake up. It is permitted to count sefira after hamapil since according to most poskim hamapil is a birchat hashevach and not birchat hanehenin.
- Mishna Brurah 239:6 writes that there are those that are more strict and make you stand but we are lenient.
- Piskei Teshuvot 239:3 based on Eliya Rabba 239 quoting the Maharitz Chayus
- Aruch HaShulchan 231:6, Kaf HaChaim 238:10
- Kaf HaChaim 231:7
- Mishna Brurah 239:9
- Or Letzion 2:15:13
- Gemara Brachot 5a, Magen Avraham 239:6, Halacha Brurah 239:8