The invention discloses an explosion-proof coil which comprises a winding (1) and a winding shell (2). A cable mounting part (3) and a circuit board (4) are arranged on the winding shell (2). A leading wire (5) is installed on the circuit board (4). A protection sleeve (6) is arranged outside the leading wire (5). A housing (7) is further fixedly connected outside the winding shell (2). The top end of the housing (7) is higher than the bottom end of the protection sleeve (6). The housing (7), the cable mounting part (3), the circuit board (4), the leading wire (5) and part of the protection sleeve (6) are formed into a whole through encapsulation. Compared with the prior art, encapsulation of the bottom end of the protection sleeve (6) is achieved through the explosion-proof coil, the electric insulation performance of the joint of the circuit board (4) is guaranteed, the explosion-proof performance of the explosion-proof coil is improved, the explosion-proof coil is made to meet the national certification requirements for explosion-proof coils, and meanwhile, market requirements for the explosion-proof coil of an electronic expansion valve can also be met. The invention further provides the electronic expansion valve with the explosion-proof coil applied and a machining method of the explosion-proof coil.