Catalyzes the oxidative demethylation of sarcosine to yield glycine, hydrogen peroxide and 5,10-methylenetetrahydrofolate. H2O + O2 + sarcosine = formaldehyde + glycine + H2O2 Belongs to the GcvT family.