The severe deterioration of the marine ecosystem significantly negatively impacts the performance of solar-driven steam generation (SSG) and the quality of the obtained freshwater. Herein, a bifunctional Ag/MgFe2O4@SCW reactor with a sandwich structure is designed for efficient SSG and Cr(VI) reduction, which is constructed via in situ deposit Ag nanoparticles (NPs) and MgFe2O4 onto surface carbonized wood (SCW). Owing to the advanced sandwich structure and strong interfacial interactions between each component, an ultra-high evaporation rate of 1.55kg m-2 h-1 and the efficiency of 88.6% are achieved using Ag/MgFe2O4@SCW under 1 sun. The system exhibits the long-term evaporation performance in the simulated sewage and strong acid/base solutions along with water-harvesting capacity in outdoor solar desalination. The quality of distilled water after desalination of actual seawater and NaCl solutions with different concentrations meets the WHO-recommended drinkable water standards. Furthermore, Ag/MgFe2O4@SCW shows outstanding antibacterial property, self-desalting capacity, as well as reusability and structure stability. Most importantly, the fast carrier separation endows Ag/MgFe2O4@SCW with superior photocatalytic activity and Cr(VI) photoreduction of up to 96.1% after 180min of illumination. The bifunctional Ag/MgFe2O4@SCW reactor provides an advanced synergistic mechanism for improving SSG and photocatalytic performance, while being promising for solar-powered production of clean water.