Electrolyzer for producing a hydrogen-oxygen mixture contains an electrolyte tank with electrodes placed in it, as well as a liquid circulating electrolyte cooling system with pipelines, an expansion tank, a circulation pump, a tubular refrigerator, and a fan for blowing atmospheric air on the external heat exchange surface of the tubular refrigerator. A thermoelectric generator based on Peltier elements is mounted on the external heat exchange surface of the tube refrigerator and connected to the useful electrical load via an electrical circuit.