The widespread occurrence of hydrazine residues in the environment, including in water, soil, and organisms, is a potential health threat to humans. Therefore, the development of an efficient method for the detection of hydrazine in environmental samples is highly desirable although it poses a significant challenge. In this study, we designed and synthesized a series of naphthalene-based fluorescent dyes through structural engineering and developed a novel probe for hydrazine detection. The probe could provide a distinct fluorescence response toward hydrazine in aqueous solution with high sensitivity and selectivity. Moreover, paper-based test strips can be easily fabricated using this probe, enabling the portable on-site detection of hydrazine with the aid of a smartphone. Furthermore, we demonstrated that this probe is capable of recognizing hydrazine in various environmental samples, including water, soil, plants, and zebrafish embryos. This research provides a promising tool for the detection of hydrazine in the environment.