Coenzyme F420 is a specialized redox cofactor with a negative redox potential. It supports biochemical processes like methanogenesis, degradation of xenobiotics, and the biosynthesis of antibiotics. Although well-studied in methanogenic archaea and actinobacteria, not much is known about F420 in Gram-negative bacteria. Genome sequencing revealed F420 biosynthetic genes in the Gram-negative, endofungal bacterium Paraburkholderia rhizoxinica, a symbiont of phytopathogenic fungi. Fluorescence microscopy, high-resolution LC-MS, and structure elucidation by NMR demonstrated that the encoded pathway is active and yields unexpected derivatives of F420 (3PG-F420). Further analyses of a biogas-producing microbial community showed that these derivatives are more widespread in nature. Genetic and biochemical studies of their biosynthesis established that a specificity switch in the guanylyltransferase CofC reprogrammed the pathway to start from 3-phospho-d-glycerate, suggesting a rerouting event during the evolution of F420 biosynthesis. Furthermore, the cofactor activity of 3PG-F420 was validated, thus opening up perspectives for its use in biocatalysis. The 3PG-F420 biosynthetic gene cluster is fully functional in Escherichia coli, enabling convenient production of the cofactor by fermentation.