Electrocoagulation (EC) is one of the effective ways of removing colour, turbidity and chemical oxygen demand from wastewater. In spite of the high-power consumption, EC has been gaining increasingly more attention due to its simplicity and effectiveness compared to the technical challenges and costs of conventional processes. Conductivity and pH are the main factors that affect the efficiency of wastewater treatment and its cost. Controlling the conductivity and pH of a wastewater treatment system is very important since it directly determines the amount of energy that must be used. We propose the use of fuzzy logic to control both conductivity and pH during the EC process, and we apply this approach in the treatment of textile wastewater. Removal efficiencies and operating costs of the EC process for dynamic and fuzzy-controlled cases are compared.