Electrostatic spraying is a new generation of green and efficient cooling/lubrication technique in machining. Critical heat flux reflects the heat transfer potential of electrostatic spraying. In this paper, an evaluation device for cooling capacity of electrostatic spraying is developed to study the effects of voltage, target distance, flow rate of nanofluids, and volume fraction of nanoparticles on critical heat flux by transient heat transfer tests. The electrostatic field between the nozzle and the heat transfer surface is simulated to analyze the heat transfer mechanism. The results show that the critical heat flux is greatly affected by the thermophysical properties of nanofluids, the electric field strength, and the deposition of nanoparticles on the heat transfer surface. Under the cone-jet mode, increasing voltage, flow rate of nanofluids, and volume fraction of nanoparticles and reducing target distance can considerably increase critical heat flux. The maximum critical heat flux can be obtained when the voltage, target distance, flow rate of nanofluids, and volume fraction of nanoparticles are taken as − 8.4 kV, 15 mm, 0.63 ml/min, and 0.15%, respectively.