Simultaneous organic halogenation coupled with hydrogenation are realized by on-site electrochemical production of halogen and hydrogen gases.