Praying and learning Torah near a bathroom:
It is Biblically forbidden to learn Torah or pray within the sight or within a four cubit radius [i.e. two meters] of the walls of a bathroom, just as it is prohibited to learn or pray within the sight or within four cubits of actual excrement. This restriction however only applies to bathrooms that do not share walls with other rooms, such as mobile bathroom usually found by events, or bathrooms found in parks which are housed in their own designated building. It is forbidden to even think Torah within the above area. This law applies even if the door of the bathroom is closed, and even if the bathroom is clean of any excrement.
A bathroom which shares its walls with other rooms: Any walled bathroom which shares its walls with other rooms, [such as a bathroom that is in a house of which the bathroom wall is also a house wall], do not have the Halachic status of a bathroom and it is thus allowed for one learn Torah or pray within a four cubit radius of its walls and within its sight. (Nevertheless, one may not learn or pray [within four cubits of] the actual toilet, or when he is facing the toilet and the toilet is within his sight.)
It is permitted to learn and pray near the walls of a bathroom that is in a house or building. One may not pray or learn within two meters of the toilet if the bathroom door is open. Likewise, one may not pray if the toilet is within his sight. It is forbidden to pray within two meters of the walls of a mobile bathroom, or external bathroom building. Likewise, one may not pray or learn when this bathroom is within one’s sight.
May one pray or learn Torah at a park if he can see the bathroom walls?
If the bathroom in the park is its own structure, such as a mobile bathroom, or a building that is designated only as a bathroom, then one may not learn or pray within its four cubits [i.e. two meters]. Likewise, one may not learn or pray if the bathroom is within one’s view, even if he is further than four cubits. One is to thus turn his back to the bathroom walls to be allowed to pray and learn.
May one pray or learn in a house/Shul if he can see a mobile bathroom from his open door/window?
This matter is disputed in Poskim. Practically, although the main ruling follows the lenient opinion, nevertheless it is best to be stringent that the bathroom not to be within one’s sight. [This stringency however is only required if the window or door is open, as according to all opinions there is no issue in seeing the mobile bathroom through a closed transparent window or door.] Likewise, according to all it suffices to close one’s eyes when inside the house even if one is facing it, and at night, if one cannot see the bathroom due to lack of light, it is permitted to pray or learn in one’s house even if one is facing it through an open window or door.
May one pray or learn in his house if the bathroom door is open?
If one can see the toilet or the floor, and the floor is dirty with urine, then one may not do so. Likewise, if he is within two meters of the toilet, or the dirty floor, he may not do so. If one cannot see the toilet and is not within two meters of the toilet then it is permitted.
 Admur 83:1 based on Taz 83:1; Elya Raba 83:2; Soles Belula 83:1; Chayeh Adam 3:11; Chesed Lealafim 83:2; Ruach Chaim 79:2; Ketzos Hashulchan 10:11; Kaf Hachaim 83:4; M”B 83:5; Although many Poskim today are lenient for various reasons, as mentioned below, practically the Sheivet Halevy 4:10 rules stringently and so is implied from Admur and other Poskim above that do not mention the distinctions below.
The Michaber 83:1 rules that it is forbidden to pray or learn Torah near an area designated for bathroom use. If however the bathroom contains walls then it is permitted to learn or pray near the bathroom without hesitation. The Michaber does not differentiate between walls of a house or walls of a mobile bathroom, and thus according to him all bathrooms with walls do not have a status of feces. In the Beis Yosef he writes that even if the walls do not reach 10 Tefach from the ground it is permitted so long as one cannot see the floor of the bathroom. The Magen Avraham [83:1] argues on the Michaber and rules that one is to be stringent to forbid learning or praying near the walls of any bathroom even if the walls are ten Tefach high [and even if they share walls with other rooms]. Those that desire to be lenient may only do so if the walls are ten Tefachim high and the bathroom does not reek of feces or urine. The Taz [83:1] likewise argues on the Michaber and rules that it is forbidden to learn or pray even near a walled bathroom. However the Taz concludes that in his opinion this only applies by bathrooms that have their own walls as opposed to a bathroom found in a building that shares walls with other rooms. Admur, as well as all the Poskim listed above, rule like the Taz.
Other Opinions: Some Poskim are lenient and rule that one may always learn and pray outside a bathroom, near the walls [Michaber ibid; Aruch Hashulchan 83:8 [being the walls are considered like walls of a house]; Eretz Tzevi 1:11 and Chazon Ish 17:1 [being the feces do not touch the actual walls of the bathroom]; Salmas Chaim 104 [being that the feces are flushed down right away and is hence not considered a bathroom]; Daas Torah and Halichos Shlomo 20:38 [Being that the walls today are made of a few sheets of plaster]; See also Shulchan Hatahor 83:2; Ashel Avraham Butchach; The Sheivet Halevy 4:10 agrees with ruling of Admur that it is forbidden and argues on the Chazon Ish saying one cannot novelize such a distinction between walls that become dirty and those that don’t. Piskeiy Teshuvos 83:2 rules leniently based on all the above Poskim.]
Today’s bathrooms hat have the feces flushed down right away: In 83:4 Admur rules that a bathroom which is made in a way that the feces and urine immediately leave to a different area are not considered a bathroom. Some [Salmas Chaim; Piskeiy Teshuvos ibid] rule based on this that our bathrooms are not considered bathrooms and it is hence permitted to learn Torah near them even if they are a separate building that do not share walls. Practically however one cannot compare our bathrooms to the above bathrooms in discussion being that the feces do not leave right away and remain in the toilet until it is flushed.
 The reason for distancing from the actual walls is because the walls themselves are considered like a “potty of feces” being that this is the use that they have been designated and used for. [ibid]
 Lit. near
 Parentheses in original; So writes also Piskeiy Teshuvos 83:2; See Chikrei Halachos 6 p. 42 for explanation of the doubt here in Admur; Vetzaruch Iyun as to the intent of Admur here: Is he referring to a case that the door is open and in such a case one may not be within four cubits of the toilet or within its sight, or does he refer to even a case that the door is closed? Also how does this ruling not contradict the ruling in 79:5 that when the Tzoa is in a different area one may be within four cubits of it, even if it is visible. Vetzaruch Iyun. To note the Ketzos Hashulchan ibid omits this ruling in his summary and simply writes one may learn and pray near such a bathroom.
 Based on above ruling
 Admur 79:5 and Michaber 79:2 regarding having feces in the next room and according to Admur the same applies in this case of mobile bathrooms outside one’s home, being that a mobile bathroom is viewed as feces according to Admur ibid.
 Regarding a person being in a different room than the feces, Admur ibid rules as follows: If a person is in one room reading the Shema and the feces are in another room, then even if the door is opened between the two rooms and he is sitting by the opening which is near the feces, nevertheless it is permitted to read the Shema in that area so long as he does not smell the feces. The reason for this is because the opening of the room is considered as if it is closed, being that it contains doorposts [Lit. Gifufim] that separate it from the room that contains the feces. [1st opinion in Admur ibid and Michaber ibid; Rosh Brachos 3:46] However there is an opinion [Rashba Brachos 25a; 2nd opinion in Admur and Michaber ibid] that rules it is forbidden to read the Shema while the feces is within one’s view, even when it is in a different domain. Practically, the main ruling follows the former opinion, as since the feces is in another room it is not relevant whether he can see it, as it is considered like feces in a glass container of which all agree that there is no prohibition in seeing it. [Thus, the feces may be within 4 amos of the person outside the room and the door may be open with the visible feces.] Nevertheless, it is proper to suspect for the latter opinion [and not have the feces within one’s sight]. [Admur ibid; Beis Yosef; Ateres Zekeinim 79:2]
 As this is similar to feces that are in a glass container of which all agree do not contain a prohibition.
 Admur ibid; M”A 79:8
The reason: As since he is in a different domain and does not physically see it, all agree it is permitted. [ibid]
 See Piskeiy Teshuvos 83:2
1. Question: [Tuesday, 23rd Mar Cheshvan, 5781]
Hi, thank you for your informative article regarding the allowance to pray near the door of the bathroom of your home due to being considered a shared wall unlike a mobile bathroom. There were a couple points that weren’t clear to me from this article.
A) Originally you write that even regarding a house bathroom, “one may not learn or pray [within four cubits of] the actual toilet,” but in the summary you add “if the bathroom door is open.” What about if the door is closed, but you are within 4 amos of the actual toilet on the other side of the door? May 1 pray next to a closed door of the bathroom if it is within four cubits of the toilet?
B) Regarding “shared walls,” is it considered a shared wall even if the bathroom is along the exterior wall of the house, and you are davening outside of the house right opposite the portion of the bathroom? And in this case, what if the actual toilet is near the exterior wall, and it comes out you are standing within 4 amos of the toilet even though you are outside the house. (This is relevant by outdoor minyanim in between houses.)
C) If a bathroom is built protruding from the wall, i.e., within a rectangular room, there is a box protruding from the side wall that houses a bathroom (see diagram below – this is the setup of a shul I’ve been to). Are these three walls considered purely for the bathroom, or are they still considered shared walls? Does it make a difference if they reach all the way to the ceiling or not?
Good questions. While I have not seen any direct discussion of these matters in the Poskim I will try to answer them in accordance to my understanding and analysis of the Halacha.
a) While from the text this matter seems unclear as you state, nonetheless in my opinion one must conclude that it must be referring to an open door as otherwise it would contradict a law brought elsewhere regarding actual feces that if it is in a different area you may pray even if it is within four cubits of you. Thus in order to avoid this contradiction one must conclude that it refers to an open door. I actually addressed this in the footnotes. So practically if the door of the bathroom is closed you may pray even right next to it even if you’re within four cubits of the toilet. If the doors open then based on the ruling of Admur in the text in parentheses one should not pray within four cubits of the toilet even if he has turned around and will not see it.
b) In my opinion the answer is that yes it is still considered a shared wall being that it is part of the general structure of the home and serves as both the external wall of the home as well as the inner wall of the bathroom and therefore it is permitted to pray outside this wall even adjacent to it and even within four cubits of the toilet as explained previously
c) Yes, I am indeed familiar with this type of structure and actually lived in a home that had this type of bathroom which was made in a protruding addition from the house. While there certainly is more question relevant here regarding its status, practically I would again conclude as I answered you in the previous question in B, that it is not considered like feces being that at the end of the day it still serves as an external wall to the home. Only if this external bathroom was constructed in a way that the external walls of the house were already built, and afterwards one went ahead and constructed a bathroom outside one of the walls through which the entrance is from the outside, then in such a case I would agree that it’s walls are considered like feces as its walls have nothing to do with the house and are completely their own structure for the sake of the bathroom. However, I would state that if an entrance path was made through the house into this newly constructed external bathroom then it would lose its status as feces and become part of the structure of the house being defined as an external wall. The fact that it protrudes should not make any difference in this matter.