Stable single-molecule switches with high on–off ratios are an essential component for future molecular-scale circuitry.