A stopped-flow microfluidic fluorimetric biosensor to monitor alkaline phosphatase (ALP) activity and evaluate the potential inhibitors has been developed, integrating a magnetically retained enzyme microreactor (MREµR) in the reaction/detection zone of the microfluidic chip. The integration supposed the alignment of the MREµR at the sample compartment of a conventional spectrofluorometer using a 3D-printed device. The analytical signal is based on the fluorescence decrease in the signal obtained in the dephosphorylation reaction of the substrate 4-methylumbelliferone phosphate (4-MUP) by the retained ALP-MNPs in an alkaline medium caused by sulfonamides. The excitation and emission wavelengths to monitor the reaction were 363 and 444 nm, respectively. Three sulfonamides, acetazolamide, furosemide, and sulfasalazine, have been used as model analytes. The front-face operating mode of the spectrofluorometer was used to acquire the instrumental signals. The influence of the rotation angle of the microfluidic device on the efficiency of the signal collection has also been studied, obtaining the signals with greater intensity at 75° from the excitation beam. The dynamic range of the calibration graph was 16.81–1111.22 µg mL−1, expressed as sulfonamide concentration, with a limit of detection of 5.04 µg mL−1(R2= 0.9989,n= 10,r= 3) for acetazolamide. The method was applied to determine sulfonamide residues in tap water and milk samples, with 88.9–98.7% recovery values. The results have been compared with those obtained using a commercial device connected to the spectrofluorometer, getting faster reaction kinetics.Graphical abstractSupplementary InformationThe online version contains supplementary material available at 10.1007/s00604-023-05786-z.