Here, a novel antibacterial agent (IM-POP-Ag) through encapsulation of Ag nanoparticles (AgNPs) into an imidazole-based porous organic polymer (IM-POP) was developed for synergistic antibacterial and wound healing. IM-POP with an ultrahigh N content of 38.42 at% was synthesized via the copolymerization of cheap and industrially mass-produced imidazole-2-carbaldehyde and melamine, via catalyst-free Schiff base chemistry, which could realize the effectively anchor of Ag on the porous skeleton (with an Ag loading of 26.01 wt%), avoiding the aggregation and reducing the toxicity of AgNPs greatly. The inherent porosity of POP realizes the effectively control on the size of AgNPs and the coordination of Ag+ changed imidazole into imidazolium, gifting the antibacterial activity to the carriers. As a result, IM-POP-Ag presented a synergistic antibacterial activity against both Staphylococcus aureus (S. aureus) and Escherichia coli (E. coli.). For example, at the same Ag content, the survival rates of E. coli and S. aureus in response to 200 μg mL−1 IM-POP-Ag (equivalent to 50 μg mL−1 AgNPs) were 3.44 ± 0.21% and 6.34 ± 0.40%, respectively, far outperforming that of bare AgNPs (12.19 ± 0.54% and 20.20 ± 0.19%). In vivo experiments on mice testified IM-POP-Ag could significantly promote the healing rate of infected wounds which could facilitate the growth of vessel and hair follicle, accelerating epithelialization. Hence, this novel and mass-produced antibacterial agent provides a new strategy and theoretical basis for the application of AgNPs with higher efficacy and biocompatibility in the near future.