A solenoid valve is described in which both an inlet and an outlet of the valve are sealed when the valve is closed. This double seal compensates for leakage at either the inlet or the outlet by making the other seal more effective in response to the leakage and allows the reversal of the flow direction by simply switching the inlet and outlet connections. The solenoid valve has a valve chamber within the valve body. Inlet and outlet tubes extend through a plate into the chamber. A movable core in the chamber extends into the solenoid coil. The distal end of the core has a silicone rubber plug. Other than when the solenoid is energized, the compressed spring biases the core downward so that the surface of the plug is in sealing engagement with the ends of the tubes. A leak at either end increases the pressure in the chamber, resulting in increased sealing force of the plug