A sensitive, eco-friendly and cost-effective 3D-integrated membrane-protected micro solid-phase extraction (3D-MP-µ-SPE) method was developed for the determination of sulfonamides (SAs) in water, milk and fish samples prior to high-performance liquid chromatography with diode array detection (HPLC-DAD). Innovatively, a 3D-printed filter holder was designed and printed by a stereolithography (SLA) printer to securely hold the µ-SPE device for extracting four SAs-: sulfadiazine (SDZ), sulfachloropyridazine (SCP), sulfamethoxazole (SMX) and sulfadimethoxine (SDM). The µ-SPE device was prepared using a nylon filter mesh, and 60 mg of Strata X was placed inside and heat sealed. Optimization parameters of the 3D-MP-µ-SPE method were studied including − type of preconditioning solvent, dosage amount, effect of drying, sample volume, number of extraction and desorption flows, type and volume of desorption solvent, and pH. Under the optimized conditions, good linearity was observed between 1 and 500 µg L−1 with an R2 of 0.9931 to 0.9994 for all the SAs. The limit of detection and quantification ranged between 0.16–0.54 µg L−1 and 0.49–1.65 µg L−1 respectively. The method demonstrated good extraction recovery (84.2 % to 114.5 %) for real sample analysis, with a relative standard deviation of less than 5.9 %. Moreover, the Analytical GREEnness (AGREE) score of 0.66 indicates the environmental friendliness of the proposed method. In conclusion, this 3D-MP-µ-SPE method offers a sustainable and efficient solution for SAs determination, with robust performance and minimal environmental impact.