Fossil stromatolites may reveal information about their hydrochemical palaeoenvironment, provided that assignment to a specific microbial community and a corresponding biogeochemical mechanism of formation can be made. Tithonian stromatolites of the Münder Formation at Thüste, north Germany, have traditionally been considered as formed by intertidal cyanobacterial communities. However, thin sections of the stromatolites show elongated angular traces of former gypsum crystals in a dense arrangement, but no algal or cyanobacterial filament traces. Moreover, high Fe2+ and Mn2+ contents, oxygen-isotope and sulphur-isotope ratios of carbonate-bound sulphates, and sulphurized hydrocarbon biomarkers of the stromatolitic carbonate indicate that CaCO3 precipitation occurred near the oxic–anoxic interface as a result of intensive bacterial sulphur cycling rather than photosynthetic activity. Furthermore, anaerobic oxidation of methane by Archaea may have driven CaCO3 precipitation in deeper parts of the biofilm community, as reflected by high concentrations of squalane with a strongly negative δ13C in conjunction with evaporite pseudomorphs showing extremely low δ13CCarb ratios. Consequently, the Thüste stromatolites are now interpreted as having initially formed by gypsum impregnation of biofilms. Subsequently, early Mg-calcitic calcitization within the biofilms occurred because of combined bacterial iron, manganese and sulphate reduction, with an increasing contribution of anaerobic oxidation of methane with depth. This model plausibly explains the prominent preservation of signals derived from oxygen-independent metabolic pathways, whereas virtually no geochemical record exists for an aerobic community that may, nevertheless, have prevailed at the stromatolite surface. Photic-zone stromatolites with a prominent signal of anaerobic oxidation of methane may be common in, and indicative of, oxygen-depleted sulphate-bearing environments with high rates of methane production, conditions that possibly were fulfilled at the Archaean to Proterozoic transition.