BackgroundThe use of antimicrobials in food animals and the emergence of antimicrobial resistance are global concerns. Ceftiofur is the only third-generation cephalosporin labeled for veterinary use in the USA, and it is the drug of choice in the majority of dairy farms for the treatment of mastitis. Here, we use next-generation sequencing to describe longitudinal changes that occur in the milk microbiome before, during, and after infection and treatment with ceftiofur. Twelve animals were intramammary challenged with Escherichia coli in one quarter and randomly allocated to receive intramammary treatment with ceftiofur (5d) or untreated controls. Serial samples were collected from −72 to 216 h relative to challenge from the challenged quarter, an ipsilateral quarter assigned to the same treatment group, and from a third quarter that did not undergo intervention.ResultsInfection with E. coli dramatically impacted microbial diversity. Ceftiofur significantly decreased LogCFUs but had no significant effect on the milk microbiome, rate of pathogen clearance, or somatic cell count. At the end of the study, the microbial profile of infected quarters was indistinguishable from pre-challenge samples in both treated and untreated animals. Intramammary infusion with ceftiofur did not alter the healthy milk (i.e., milk devoid of clots or serous appearance and collected from a mammary gland that shows no clinical signs of mastitis) microbiome.ConclusionsOur results indicate that the mammary gland harbors a resilient microbiome, capable of reestablishing itself after experimental infection with E. coli independent of antimicrobial treatment.Electronic supplementary materialThe online version of this article (doi:10.1186/s40168-017-0291-5) contains supplementary material, which is available to authorized users.