In this study, a new, affordable, and promising adsorbent based on MnCoCu-LDHs@MOF-235(Fe) nanocomposite was successfully synthesized, characterized, and utilized for the solid phase extraction of diniconazole (DNC) pesticide from water and food samples before it was determined by liquid chromatography. The structural characteristics of the synthesized nanocomposite were confirmed by various techniques, including FTIR, XRD, FE-SEM, and FE-SEM-EDX. The central composite design (CCD) technique was used for multi-response optimization of effective parameters including the sample solution’s pH (6.0), adsorbent amount (15 mg), adsorption time (5 min), sample volume (30 mL) and eluent volume (2.5 mL), and desorption time (3 min) to achieve optimum extraction efficiency. Under optimal conditions, the method’s analytical performance was assessed. The results showed that the calibration graphs showed linearity for DNC in the range of 1.3–500 µg L−1, with a detection limit of 0.4 µg L−1 and a correlation coefficient of 0.9988. Additionally, 2.9 intra-day RSD, 6.1 inter-day RSD, 12.0 preconcentration factor, and 2.53–11.53 enrichment factors was attained. The performance of the method to extract DNC from nine different real samples was realized with high relative recoveries (88.0–108 %). In addition, the greenness of the method was assessed with the AGREE metric tool, confirming that the method is environmentally friendly.