The fabrication of anti-biofouling nanofiltration (NF) membrane is one of the effective methods to improve the vulnerability of membranes to bacteria in the feed solution. The prevalent approach to prepare anti-biofouling NF membranes is to graft biotoxic substances onto the NF membrane surface to kill the attached bacteria, inducing antimicrobial resistance in bacteria and water safety problem. In this study, non-biotoxic methyl 2-aminobenzoate (MA) was employed to prepare the anti-biofouling NF membranes. Instead of killing bacteria, the modified NF membrane could effectively prevent proliferation of bacteria on the membrane surface by blocking the quorum sensing in bacteria, thereby avoiding the generation of antimicrobial resistance. On the condition that the bacteria are alive, the biofilm formed by Escherichia coli (E. coli) and Bacillus subtilis (B. subtilis) on the modified NF membrane were significantly reduced by 94.5% and 65.1%, respectively. Additionally, the modified membrane showed superior anti-adhesion property for proteins and polysaccharides, attributing from the improved hydrophilicity of membrane surface. The optimally modified membrane exhibited the enhanced water permeability (from 6.72 L m-2h−1 bar−1 to 12.12 L m-2h−1 bar−1) and un-degraded divalent salt rejection (98.4% of Na2SO4). This work provided an efficient and non-biotoxic approach for the fabrication of environmental friendly anti-biofouling NF membranes, which would eliminate the worries about the water safety and the development of antimicrobial resistance in bacteria.