The present work aims to optimize the leachate treatment of the Mohammedia-Benslimane landfill by coagulation-flocculation using the central composite design. The independent variables studied were pH, coagulant dose, flocculant dose, and stirring time. The response variables studied were turbidity, COD, and absorbance at a wavelength of 254 nm. The results showed that the optimal pH was 6.87, the optimal coagulant dose was 7.89 g/L, the optimal flocculant dose was 12 ml/L, and the optimal stirring time was 22.8 min. These optimal conditions provided the best results for the responses studied. Indeed, turbidity was reduced by 90.38%, COD was reduced by 85.50%, and absorbance at a wavelength of 254 nm was decreased by 55.53%. The analysis of variance indicated that the established models were significant and that they are characterized by a good fit (R2 in the order of 0.97, 0.96, and 0.94 for turbidity, COD, and UV254, respectively). In conclusion, optimizing landfill leachate treatment by flocculation coagulation using the central composite design within response surface methodology yielded promising results for reducing turbidity, COD, and absorbance at a wavelength of 254 nm. This method can be used to optimize landfill leachate treatment in other settings.