Sulfate reduction is an essential metabolism that maintains biogeochemical cycles in marine and terrestrial ecosystems. Sulfate reducers are exclusively prokaryotic, phylogenetically diverse, and may have evolved early in Earth’s history. However, their origin is elusive and unequivocal fossils are lacking. Here we report a new microfossil, Qingjiangonema cambria, from ∼518-million-year-old black shales that yield the Qingjiang biota. Qingjiangonema is a long filamentous form comprising hundreds of cells filled by equimorphic and equidimensional pyrite microcrystals with a light sulfur isotope composition. Multiple lines of evidence indicate Qingjiangonema was a sulfate-reducing bacterium that exhibits similar patterns of cell organization to filamentous forms within the phylum Desulfobacterota, including the sulfate-reducing Desulfonema and sulfide-oxidizing cable bacteria. Phylogenomic analyses confirm separate, independent origins of multicellularity in Desulfonema and in cable bacteria. Molecular clock analyses infer that the Desulfobacterota, which encompass a majority of sulfate-reducing taxa, diverged ∼2.41 billion years ago during the Paleoproterozoic Great Oxygenation Event, while cable bacteria diverged ∼0.56 billion years ago during or immediately after the Neoproterozoic Oxygenation Event. Taken together, we interpret Qingjiangonema as a multicellular sulfate-reducing microfossil and propose that cable bacteria evolved from a multicellular filamentous sulfate-reducing ancestor. We infer that the diversification of the Desulfobacterota and the origin of cable bacteria may have been responses to oxygenation events in Earth’s history.