In this study, the effects of operational parameters such as initial pH, current density, and electrolysis time on the treatment of transport container washing wastewater by electrocoagulation (EC) with aluminum (Al) and iron (Fe) electrodes were investigated separately. Chemical oxygen demand (COD), turbidity and color were used to measure the treatment efficiency. Energy consumptions were calculated per cubic meter of wastewater. Amount of sludge produced after EC was also reported per cubic meter of wastewater. Different direct and indirect cost items including energy, sacrificial electrodes, labor, sludge handling and disposal, maintenance, and depreciation costs have been considered in the calculation of the total operating cost, and it was calculated as per cubic meter of wastewater and per kilograms of COD removed. The total operating costs were acquired as 11.2 $m−3 with 79.45% of COD, 99.71% of color, and 99.45% of turbidity removal efficiencies by Fe electrodes and 23.89 $ m−3 with 76.31% of COD, 99.05% of color, and 99.77% of turbidity removal efficiencies by Al electrodes under the optimum parameters in this study. In addition, the optimum operating times were found as 30 min for Fe electrodes and 60 min for Al electrodes. © 2012 American Institute of Chemical Engineers Environ Prog, 32: 249‐256, 2013