A fluorescent probe for the detection of a metallo-β-lactamase (IMP-1), N-[2-(5-dimethylaminonaphthalen-1-ylsulfonylamino)ethyl]-3-mercaptopropionamide (DansylC2SH), 1, was designed based on combining the inhibitory function of mercaptocarboxylate and a fluorophore. The binding of 1 to IMP-1 was investigated by fluorescence spectroscopy. Compound 1 can act as fluorescent probe for detecting IMP-1 selectively.