Efficient H2O2 production both on a nickel carbonate cathode and a photoanode using only H2O, O2, and solar light, was achieved without using an external bias or a membrane.