BackgroundMycoplasma hyorhinis is a prevalent respiratory pathogen in swine, causing significant economic loss to pig producers. There is growing evidence that respiratory pathogen infections have a large impact on intestinal microecology. To study the effect of M. hyorhinis infection on gut microbial composition and metabolome profile, pigs were infected with M. hyorhinis. Metagenomic sequencing analysis was performed of fecal samples and a liquid chromatography/tandem mass spectrometry (LC–MS/MS) analysis of gut digesta was made.ResultsPigs infected with M. hyorhinis had enriched Sutterella and Mailhella, and depleted Dechloromonas, Succinatimonas, Campylobacter, Blastocystis, Treponema, and Megasphaera. The pigs infected with M. hyorhinis also had greater abundances of bacterium_0_1xD8_71, Ruminococcus_sp__CAG_353, Firmicutes_bacterium_CAG_194, Firmicutes_bacterium_CAG_534, bacterium_1xD42_87, and lower abundances of Chlamydia_suis, Megasphaera_elsdenii, Treponema_porcinum, Bacteroides_sp__CAG_1060, Faecalibacterium_prausnitzii. Metabolomic analysis revealed that some lipids and lipid‐like molecules increased in the small intestine, whereas most lipids and lipid‐like molecule metabolites decreased in the large intestine. These altered metabolites induce changes in intestinal sphingolipid metabolism, amino acid metabolism, and thiamine metabolism.ConclusionThese findings demonstrate that infection with M. hyorhinis can alter the gut microbial composition and metabolite structure in pigs, which may further affect amino acid metabolism and lipid metabolism in the intestine. © 2023 Society of Chemical Industry.