The article has investigated the operation of the electrical complex of a resistance welding machine with thyristor current regulation. The model of the resistance welding process is presented as a control object with known input parameters, output parameters and external disturbances. The input parameters are the following: the preset welding current, a mode parameter (hard, soft), the prearranged welding time, the preset compression force, etc. The output parameters related to welding quality are the following: welding current, electrodes voltage, welding energy, resistance of the section «electrode-the part-electrode». The output parameters related to the indicators of ensuring electromagnetic compatibility of the electrotechnical complex with the electrical network are the following: the current consumed from the electrical network, reactive power consumed from the network, PF (power factor), THDI (current’s total harmonic distortion), load asymmetry coefficient. The external disturbing factors, the effect of which leads to the deterioration of the quality of welded joints are the following: fluctuations of the supply voltage, change of resistance of the welding circuit caused by the ferromagnetic masses, change of the welding circuit resistance due to its heating and/or wear, wear of the electrodes, change of the state of the welding parts surfaces, welding current bypass. The influence of disturbing factors on the welding process has been analyzed and it has been confirmed that in order to ensure a high-quality welded joint, it is necessary to stabilize the energy released in the welding contact. A model has been developed that simulates a change in the resistance of the welding circuit during the welding cycle. A model of the energy stabilization subsystem has been developed; it calculates the energy that is released in the welding contact and, when it reaches the preset value, the machine is turned off. To calculate the required energy, the heat balance equation was used, that takes into account both the useful energy, spent on the creation of the welded joint and the energy losses due to heat removal to the electrodes, to the welded parts, and convective heat transfer (which is usually neglected). The obtained results of the useful energy calculation take into account the latent heat of fusion. As a result of the simulation, it has been shown that the release of the necessary amount of energy, given welding current, results in an increase in the welding duration: taking into account the changes in resistance during welding, the welding duration grows up to 20%, taking into account the voltage fluctuations (-15%) the welding duration grows up to 30%. Under the influence of both disturbing factors, the welding duration can increase up to 60%, provided that the necessary welding quality is ensured. Thus, it has been shown that besides the magnitude of the welding current, it is possible to adjust the duration of welding, providing the necessary energy in the welding contact (taking into account the restrictions on the duration of current)