Water Inlet Valve
Try shutting off power to the washer. If the washer still overflows even when it is not getting power, this indicates that the water inlet valve is defective. If the water inlet valve is defective, replace it.
The pressure switch shuts off power to the water inlet valve when the proper water level is reached. If the pressure switch fails, the water inlet valve will continue to fill the washer tub with water, causing the washer to overflow. Before replacing the pressure switch, check the air tube to the pressure switch to ensure that it is clear of debris and is not leaking.
Low Water Pressure from House Supply
The water pressure to the water inlet valve might be too low. The water inlet valve requires a minimum of 20 psi to shut off properly. If the water inlet valve does not get enough pressure, the valve may not close fully after the power is shut off. As a result, water can leak into the washer and cause it to overflow. Check the water pressure to determine if it is sufficient.