Conventional polyamide and polyester thin film composite membranes (TFCMs) are susceptible to harsh conditions, because the amide and ester bonds in them will degrade under extreme pH or chlorine oxidants. This work addressed this problem by preparing TFCMs through the Hoffmann alkylation reaction. Two monomers, i.e., 1,4,7,10-Tetraazacyclododecane (TAD) and 1,2,4,5-Tetrakis(bromomethyl)benzene (TBB), were designed and underwent interfacial alkylation on polyacrylonitrile substrate. The TAD-TBB TFCMs feature high positive charge, and show good repulsion (>90%) to divalent cations. Benefiting from the stability of “C-N-C” bonds in TAD-TBB network, both the permeance (13.7 L m−2 h−1 bar−1) and cation rejection (90.3%–91.4%) of the TAD-TBB TFCMs are stable after being immersed in 2 M HCl for 21 days. Meanwhile, the TAD-TBB TFCMs maintained good separation performance (permeance: 13.9 L m−2 h−1 bar−1, MgCl2 rejection: 90.5%–92.2%) after a total free chlorine exposure of 96000 ppm h (200 ppm for 480 h). This work reported the preparation of cation-selective membranes stable in harsh environments.