A mercury switch is an electric switch whose purpose is to allow or interrupt the flow of electric current in an electrical circuit in a manner that is dependent on the switch's physical position or alignment relative to the direction of the "pull" of earth's gravity.

Mercury switches consist of a set of electrical contacts in a sealed glass envelope which contains a bead of liquid mercury. When the switch is tilted in the appropriate direction, gravity pulls the liquid mercury in a downward direction, causing the mercury to touch the contacts, thus completing the electrical circuit. Tilting the switch the opposite direction causes the mercury to move away from the contacts, thus breaking the circuit.

Mercury switches are commonly used in thermostats and mechanical systems that are controlled electrically where the physical orientation of actuators or rotors is a factor.