AbstractMicrobiologically influenced corrosion is a common problem in the industrial field due to the deterioration of metals in the presence of various microorganisms, in particular sulfate-reducing bacteria (SRB) and sulfur-oxidizing bacteria (SOB). A common method to reduce microbiologically influenced corrosion is the application of biocides. The limited number of suitable biocides and the resulting development of resistance, high dosage, and high application rate hinder an effective application. An environmentally friendly alternative could be the application of antimicrobial peptides (AMP), which have already been established in the field of medical devices for a while. Here, the successful treatment of different AMPs against 3 SRB and 1 SOB was demonstrated. The peptide L5K5W was favored due to its broad activity, high stability, and simple structure resulting in low synthesis costs. An alanine scan showed that substitution of leucine with tryptophan increased the activity of this peptide twofold compared to the original peptide againstD. vulgaris, the main representative of SRB. Additional optimization of this modified peptide through changes in amino acid composition and lipidations significantly increased the effectiveness, finally resulting in a minimum inhibitory concentration (MIC) of 15.63 μg/mL againstDesulfovibrio vulgaris. Even against the marine SRB Desulfovibrio indonesiensis with a required salt concentration of min. 2%, an activity of the peptides can be observed (MIC: 31.25 μg/mL). The peptides also remained stable and active for 7 days in the supernatant of the bacterial culture.Key points• Antimicrobial peptides provide an alternative to combat biocorrosive bacteria.• Optimization of the peptide sequence leads to a significant increase in activity.• The investigated peptides exhibit high stability, both in the medium and in the bacterial supernatant.Graphical abstractSupplementary InformationThe online version contains supplementary material available at 10.1007/s00253-023-12562-9.