High-resolution core-level photoemission spectroscopy and temperature-programmed reaction experiments together with density functional theory calculations were used to elucidate on the atomic scale the chlorination mechanism of ruthenium dioxide RuO2(110) by hydrogen chloride exposure. The surface-selective chlorination accounts for the extraordinary stability of the RuO2 catalyst in the Sumitomo process — the heterogeneously catalyzed oxidation of hydrogen chloride by oxygen. The selective replacement of bridging oxygen atoms by chlorine atoms depends on the formation of water molecules serving as leaving groups. Water is produced by the chlorine-assisted recombination of two neighboring surface hydroxyl groups at around 450 K, a temperature where water instantaneously leaves the surface. Finally, the bridging vacancy is rapidly filled in by chlorine atoms, thereby forming bridging chlorine atoms. Preadsorbed hydrogen has shown to facilitate the chlorination process for stoichiometry reasons. The general strategy of transforming bridging O atoms into a good leaving group has been corroborated by the chlorination of RuO2(110) via CO pretreatment with CO2 as the leaving group and subsequent Cl2 exposure.