β-galactosidase is of great significance to living organisms, which is an important marker of primary ovarian cancer and cellular senescence. To detect the activity of β-galactosidase, a novel fluorescent probe ESIPT-GAL which based on excited state intramolecular proton transfer (ESIPT) mechanism for detecting β-galactosidase is developed in this work with low background fluorescence and high sensitivity (Φ = 0.0045-0.2409). The fluorescence intensity at 552 nm of this probe increased by ~ 55 times with β-galactosidase addition (0-4 U/mL), and its detection limit is very low (3.9 × 10 U/mL). In addition, the spectral data (pseudo-first-order rate: 1.303 min) and enzyme kinetic parameter (V = 69.5 μΜ•S) both show that the probe can achieve rapid response to β-galactosidase. Moreover, the probe has good water solubility, which ensures that it has good biocompatibility and can be easily applied to detect β-galactosidase in living cells and tissues. Importantly, the probe ESIPT-GAL can monitor β-galactosidase in deep mouse tissue sections (90 μm).