Bacterial infections cause considerable morbidity and expensive healthcare costs. The prescription of broad-spectrum antimicrobial drugs results in failure of treatment or overtreatment and exacerbates the spread of multidrug-resistant pathogens. There is an emergent demand for rapid and accurate methods to identify pathogens and conduct personalized therapy. Here, we develop a herringbone microfluidic chip integrated with vancomycin modified magnetic beads (herringbone-VMB microchip) to enrich pathogens. The enriched pathogens are identified by matrix-assisted laser desorption ionization time-of-flight mass spectrometry. The herringbone-VMB microchip applies passive mixing of bacterial samples by generating microvortices, which significantly enhances the interaction between bacteria and vancomycin modified magnetic beads and leads to more efficient enrichment compared to in-tube extraction. Four common pathogens in urinary tract infections are utilized to validate the method, and the capture efficiency of the bacteria from urine is up to 90%. The whole procedure takes 1.5 hours from enrichment to identification. This method shows potential in shortening the turnaround time in the clinical diagnosis of bacterial infections.