During the CO2 fracturing process, the primary gases involved include O2, CO, CO2, and CH4. However, data on the self-diffusion coefficients of gases in transcritical CO2 are scarce, and empirical equations specifically proposed for the diffusion of small-molecule gas in transcritical CO2 are lacking. In this work, molecular dynamics simulations were used to calculate the self-diffusion coefficient of gases solute (H2, O2, CO, CH4) in transcritical CO2 at temperatures ranging from 280 to 310 K and a pressure of 75 atm. The results indicated that the temperature, density, and viscosity are the main factors affecting the self-diffusion coefficients of gas solutes. Moreover, an Arrhenius relationship was observed between the diffusion coefficients and the temperature. Therefore, we derived new parameters for an empirical equation to calculate the diffusion coefficients in transcritical CO2, achieving a mean relative error of 5.71%. Subsequently, we compared the derived equation with eight commonly used empirical equations, finding that the new equation is well-suited for calculating the self-diffusion coefficients under transcritical conditions.