Halonitrophenols (HNPs) are an emerging type of aromatic disinfection byproduct, with detected concentrations of & SIM;nmol L-1 in source water and drinking water. Currently, there are no standard methods for identifying HNPs, and most of the reported methods are time-consuming and equipment-dependent. A core-shell metal-organic framework (MOF) based electrochemical sensor (Ag/ZIF-8@ZIF-67) capable of detecting 2,6-dichloro-4-nitrophenol (2,6-DCNP) is reported in this study. The electrochemical sensor obtains the concentration of 2,6-DCNP by detecting the peak current passing through the sensor. In this sensor, Ag nanoparticles (AgNPs) play a key role in electrochemical sensing by reducing nitro groups via electron transfer, and porous structure with a large surface area is offered by ZIF-8@ZIF-67. The cyclic voltammetry (CV) response of Ag/ZIF-8@ZIF-67 was found to be approximately 1.75 times and 2.23 times greater than that of Ag/ZIF-8 and Ag/ZIF-67, respectively, suggesting an ideal synergistic effect of the core-shell structures. The Ag/ZIF-8@ZIF-67 sensor exhibited exceptional sensitivity to 2,6-DCNP, exhibiting a broad linear response range (R2 = 0.992) from 240 nmol L-1 to 288 & mu;mol L-1 and a low detection limit of 20 nmol L-1. Furthermore, the sensor exhibited good anti-interference for isomers and common distractors in water, excellent stability and reproducibility, and high recovery in actual water samples. Our reported sensor gives a novel strategy for sensitive, selective, and in situ detection of 2,6-DCNP in practical analysis. A core-shell metal-organic framework (MOF) based electrochemical sensor (Ag/ZIF-8@ZIF-67) capable of detecting 2,6-DCNP is prepared, with a broad linear response range (R2 = 0.992) from 240 nM to 288 & mu;M and a low detection limit of 20 nM.