PP2C phosphatases control biological processes including stress responses, development, and cell division in all kingdoms of life. Diverse regulatory domains adapt PP2C phosphatases to specific functions, but how these domains control phosphatase activity was unknown. We present structures representing active and inactive states of the PP2C phosphatase SpoIIE from Bacillus subtilis. Based on structural analyses and genetic and biochemical experiments, we identify an α-helical switch that shifts a carbonyl oxygen into the active site to coordinate a metal cofactor. Our analysis indicates that this switch is widely conserved among PP2C family members, serving as a platform to control phosphatase activity in response to diverse inputs. Remarkably, the switch is shared with proteasomal proteases, which we identify as evolutionary and structural relatives of PP2C phosphatases. Although these proteases use an unrelated catalytic mechanism, rotation of equivalent helices controls protease activity by movement of the equivalent carbonyl oxygen into the active site.