The rapid emergence and spread of drug-resistant pathogens pose a serious threat to human health. To overcome this problem, the exploration of new antibacterial agents, especially antibiotic-free strategies, is urgent. Here, nitric oxide (NO) release and photothermal effects were integrated into a single nanoplatform to achieve more efficient antibacterial effects. The nanoplatform (SNP/MPDA) was composed of mesoporous polydopamine (MPDA) and sodium nitroferricyanide (III) dihydrate (SNP). Near-infrared (NIR)-light could make MPDA produce high temperature, which could not only effectively kill bacteria but also induce SNPs to generate NO to kill bacteria. The NO/ photothermal strategy showed the ability to kill both Gramnegative Escherichia coli and Gram-positive Staphylococcus aureusand destruct mature biofilm. This antibiotic-free strategy had the advantage of producing NO in situ, thereby showing its high antibacterial activity and great potential in killing pathogens. This work provides insights into the design of more efficient antimicrobial strategies without antibiotics.