One may not benefit from water that was heated in a forbidden fashion on Shabbat. But if the water was heated in a permissible fashion, one may benefit from it on Shabbat. Seemingly, then, if a boiler was on before Shabbat, one could use the hot water produced by it even on Shabbat. However, there is a problem. Today’s electric boilers are built in such a way that whenever the hot water is turned on, cold water flows into the boiler tank to replace it. If the heating elements in the boiler are working and heating, then turning on the hot water tap on Shabbat causes cold water to enter the boiler and become cooked. Therefore one may not turn on the hot water on Shabbat when the boiler is on.
If the electric boiler was turned off before Shabbat, then the question whether the hot water may be used depends on whether the cold water that will flow into the boiler will become cooked. If the hot water coming out is scalding, it would be forbidden to turn on the hot water tap, because the replacement cold water would become cooked. But if the hot water is cool enough to touch, even just barely, then even if it is yad soledet bo it can be used on Shabbat, because the remaining water in the boiler cannot cook the incoming cold water (as explained in the note). When it is unclear whether the hot water is hot enough to cook the incoming water, one may turn on the faucet, as this is only forbidden if it is clear that the cold water entering the boiler will become cooked. If it is initially unclear how hot the water is, but when the faucet is turned on it becomes clear that it is extremely hot, cold water should be added to reduce the water’s temperature to below yad soledet bo.
One may also set the electric boiler on a timer that will turn it on for 15 minutes every few hours. This way, the water will heat somewhat, but will not reach yad soledet bo. One can then use the lukewarm water on Shabbat without worrying.
. Although some maintain that yad soledet bo is the temperature at which it is unpleasant to touch something for an extended period of time, a temperature of approximately 45°C (see section 4 above), in this case one only needs to be stringent when the water coming out of the boiler is over 80°C and cannot be touched at all. This is because our boilers are built in such a way that the hottest water is at the top of the boiler while the water at the bottom is not as hot. (The cold water enters the boiler through the lower part.) There is a significant difference between their temperatures. If one is able to touch the hot water that comes out of the top part of the boiler, it is almost certain that the water at the bottom of the boiler is not yad soledet bo, and certainly is not capable of cooking the cold water that will enter the boiler.When in doubt, one may turn on the hot water tap and check if the water is yad soledet bo. Even if it turns out that the water is burning hot, this is not prohibited. This is because when he turned on the water there was a doubt, and this is a case of davar she-eino mitkaven. This is certainly the case according to Taz, and perhaps also according to R. Akiva Eger, because one might use so much water that the remaining water will not be able to cook anything (see above 9:2 and Harĥavot here). In addition, the flow of cold water into the boiler is caused indirectly, and without the intention to heat it (see SSK ch. 1 n. 132). One may even use the water without being considered benefiting from a melakha. Since one did not know if the water is burning hot, it was permissible for him to turn on the hot water tap. Once the burning hot water is already flowing, one may add a great deal of cold water to it so that it will no longer be yad soledet bo (because if it is yad soledet bo, then the cold water that is being added to the burning water will cook). Once the hot water is released, it is preferable to wash as many dishes as possible, so that the hot water will come out of the boiler and the remaining water in the boiler will be unable to heat the cold water flowing in. If one needs only a little hot water, some say that it is still forbidden to turn off the hot water tap until all the hot water comes out. This is to make sure that the cold water flowing in will not cook (Menuĥat Ahava 2:10:13). Others permit the tap to be closed, because the cooking is done via grama, and we are not stringent when a loss is involved (Otzrot Shabbat ch. 1, p. 61 in the name of Shevet Ha-Levi; see SSK 1, the end of n. 131). The halakha follows those who are lenient. This is because in addition to their reasoning, it is almost always still doubtful whether the water remaining in the boiler would in fact be able to cook the incoming water; even if it could, it would be a davar she-eino mitkaven, which makes the prohibition rabbinic; additionally, the action is performed via grama.
It would seem that the following applies in a time of need, such as a cold day when it is difficult to wash the dishes using cold water, and one needs to wash a large number of dishes and use a large quantity of hot water. Even if it is clear that the water in the boiler is very hot, he may still use it, by first opening the cold water tap and then the hot water tap. This way, the cold water coming into contact with the hot water will not cook. Since it is clear that one will use a lot of hot water, it is also clear that the remaining water in the boiler will not be able to cook the cold water that will flow in as a result.