Pig manure is a reservoir of antibiotics and antibiotic resistance genes (ARGs). The effect of biochar on the variations in physicochemical properties, bacterial communities, antibiotics, ARGs, and mobile genetic elements (MGEs) of compost product during co-composting of pig manure and corn straw have been investigated in this study. Compared with the control treatment (CK), biochar addition accelerated the increase in pile temperature and prolonged the high temperature period (>55°C) for 2 days. Under biochar influence, organic matter degradation, NH4+-N conversion and NO3−-N production was accelerated, and dissolved total organic carbon (DOC) and dissolved total nitrogen (DTN) utilization by microorganisms were enhanced. Biochar addition altered the microbial community and promoted the vital activity of Actinobacteria in the later composting stage. The antibiotics removal efficiency (except danofloxacin and enrofloxacin) was accelerated in the early composting stage (1–14 days) by biochar addition, the pile temperature had a positive effect on antibiotics removal, and the total antibiotics removal efficiency in CK and CK+Biochar treatments was 69.58% and 78.67% at the end of the composting process, respectively. The absolute abundance of most of the ARGs in the CK+Biochar treatment was lower than that in the CK treatment during composting, and the ARGs removal mainly occurred in the early (1–14 days) and later (28–50 days) stages. Biochar addition reduced the absolute abundance of MGEs (intI1, intI2) in the compost product, and most of the ARGs had a significant positive correlation with MGEs. Network analysis and redundancy analysis showed that ARGs and MGEs occurred in various host bacteria (Firmicutes, Actinobacteria, Bacteroidetes, Proteobacteria, and Halanaerobiaeota), and that DTN and NH4+-N are the main factors regulating the changes in bacterial communities, antibiotics, ARGs, and MGEs during composting. Moreover, MGEs contributed the most to the variation in ARGs. In summary, biochar addition during composting accelerated antibiotics removal and inhibited accumulation and transmission of ARGs. The results of this study could provide theoretical and technical support for biochar application for antibiotics and ARGs removal during livestock and poultry manure composting.