ABSTRACT Infections by filamentous phages influence bacterial fitness in various ways. While phage-encoded accessory genes, e.g., virulence genes, can be highly beneficial, the production of viral particles is energetically costly and often reduces bacterial growth. Consequently, if costs outweigh benefits, bacteria evolve resistance which can shorten phage epidemics. Abiotic conditions are known to influence the net-fitness effect for infected bacteria. Their impact on the dynamics and trajectories of host resistance evolution, however, remains yet unknown. To address this, we experimentally evolved the bacterium Vibrio alginolyticus in the presence of a filamentous phage at three different salinity levels, i.e., (1) ambient (2) 50% reduction, and (3) fluctuations between reduced and ambient. In all three salinities, bacteria rapidly acquired resistance through super infection exclusion (SIE), whereby phage-infected cells acquired immunity at the cost of reduced growth. Over time, SIE was gradually replaced by evolutionary fitter surface receptor mutants (SRM). This replacement was significantly faster at ambient and fluctuating conditions compared to the low saline environment. Our experimentally parameterized mathematical model explains that suboptimal environmental conditions, in which bacterial growth is slower, slow down phage resistance evolution ultimately prolonging phage epidemics. Our results imply that, if filamentous phages encode virulence genes, these may persist longer in bacterial populations at sub-optimal environmental conditions, which, in times of climate change, are becoming more frequent. Thus, our future ocean may favour the emergence of phage-born pathogenic bacteria, and impose a greater risk for disease outbreaks, impacting not only marine animals but also humans.