Our understanding of secondary metabolite production in bacteria has been shaped primarily by studies of attached varieties such as symbionts, pathogens, and soil bacteria. Here we show that a strain of the single-celled, planktonic marine cyanobacterium Prochlorococcus-which conducts a sizable fraction of photosynthesis in the oceans-produces many cyclic, lanthionine-containing peptides (lantipeptides). Remarkably, in Prochlorococcus MIT9313 a single promiscuous enzyme transforms up to 29 different linear ribosomally synthesized peptides into a library of polycyclic, conformationally constrained products with highly diverse ring topologies. Genes encoding this system are found in variable abundances across the oceans-with a hot spot in a Galapagos hypersaline lagoon-suggesting they play a habitat- and/or community-specific role. The extraordinarily efficient pathway for generating structural diversity enables these cyanobacteria to produce as many secondary metabolites as model antibiotic-producing bacteria, but with much smaller genomes.