In this investigation, response surface method was used to predict and optimize the surface roughness during electrical discharge machining of AISI D6 tool steel. Pulse on time, pulse current and voltage were considered as input process parameters. Also, the analysis of variance was employed for checking the developed model results. The results showed that the developed model predicted the roughness values, accurately. Also, the pulse on time was the most effective parameter influencing the roughness. Moreover, it was found that the higher values of pulse on time and pulse current and lower values of input voltage caused to in higher amounts of surface roughness. Moreover, the optimal condition to obtain a minimum of surface roughness was 10.22 mu s, 8.02 A and 174.74 V, respectively for the pulse on time, pulse current and input voltage.