The mucilage and the coffee pulp, are semi-liquid by-products involved in the generation of wastewater with high values of solids and chemical oxygen demand (COD), negatively impacting the efficiency and costs of the traditional treatments. A factorial design was applied to evaluate the removal of COD in coffee mucilage by electrocoagulation, analyzing the effects and interactions of three parameters (current intensity, pH and time) in the response variable (percentage of COD removal). The electrocoagulation process using Fe-Al electrode pair, showed a maximum removal of the COD of 46%, in a treatment time of 50 min, 3.0 A and initial pH of 6.3. The statistical analysis showed a significant effect from initial pH and treatment time in the removal of COD. The electrocoagulation is a suitable alternative for pre-treatment of liquid waste of the coffee.