Efficient and sustainable methods for 99TcO4– removal from acidic nuclear waste streams, contaminated water, and highly alkaline tank wastes are highly sought after. Herein, we demonstrate that ionic covalent organic polymers (iCOPs) possessing imidazolium-N+ nanotraps allow the selective adsorption of 99TcO4– under wide-ranging pH conditions. In particular, we show that the binding affinity of the cationic nanotraps toward 99TcO4– can be modulated by tuning the local environment around the nanotraps through a halogenation strategy, thereby enabling universal pH 99TcO4– removal. A parent iCOP-1 possessing imidazolium-N+ nanotraps showed fast kinetics (reaching adsorption equilibrium in 1 min), a high adsorption capacity (up to 1434.1 ± 24.6 mg/g), and exceptional selectivity for 99TcO4– and ReO4– (nonradioactive analogue of 99TcO4–) removal in contaminated water. By introducing F groups near the imidazolium-N+ nanotrap sites (iCOP-2), a ReO4– removal efficiency over 58% was achieved in 60 min in 3 M HNO3 solution. Further, introduction of larger Br groups near the imidazolium-N+ binding sites (iCOP-3) imparted a pronounced steric effect, resulting in exceptional adsorption performance for 99TcO4– under super alkaline conditions and from low-activity waste streams at US legacy Hanford nuclear sites. The halogenation strategy reported herein guides the task-specific design of functional adsorbents for 99TcO4– removal and other applications.