Even on Shabbat, it is good to have hot water for washing the hands and face. Perhaps one also needs to clean a baby or wash some dishes. What can be done? Hot water taken out of a boiler will be replaced by cold water, which is then heated by the hot water that remains from before, violating the Shabbat prohibition of "cooking."
Another problem with a boiler is the effect of removing water on the heating element, which is controlled by a thermostat linked to the water temperature. If the temperature decreases because cold water enters the boiler, the heating element will be turned on.
These problems are solved in a design by The Zomet Institute: An electric boiler that differs in two ways from the usual ones, solving the two problems of "cooking" the fresh water and "turning on" the heating element.
(1) A subsidiary thermostat is installed which limits the temperature on Shabbat to 40 degrees C. Halachically, this is considered water "which will not scald the hand," cold enough that it will not "cook" the fresh water. Thus, the water in the boiler never reaches a temperature prohibited by the halacha.
(2) A special mechanism operates the heating element on a fixed cycle during Shabbat, turning it on for a few seconds every fifteen minutes. Of course, such short pulses will not heat up the water at all. What good does it do? During the pulses, the Shabbat thermostat checks the temperature of the water. If it is less than 40 degrees, the heating element will not be turned off until a temperature of 40 degrees is reached (this is an application of the principle of continuing an existing status).
When these mechanisms are used, removing hot water from the boiler doesn't lead either to direct heating of the water or to turning on a heating element. All it does is to "continue" the existing state of electrical activity.
For more details, contact The Zomet Institute.