Terrestrial Gamma-ray flashes (TGFs) originating from the Earth’s atmosphere, accompanied by thunderstorms and lightning activity, are one of the hot spots in the interdisciplinary of cosmic ray and atmospheric physics. Over the years, satellite experiments have detected thousands of upward TGFs during thunderstorms, while ground-based experiments have observed some downward TGFs. Nowadays, it is widely believed that TGFs accompanying lightning leaders observed by satellite-based and ground-based experiments involve relativistic runaway electron avalanche (RREA) production. Due to triggering the relativistic runaway electron avalanche (RREA) process needing a very large electric field strength and region, it is difficult to study the RREA process through ground-based experiments. In this paper, CORSIKA 7.7410 software package, combined with a vertically uniform electric field model, is adopted to simulate the intensity and energy distribution of RREA electrons in thundercloud with different electric field strengths induced by seed electrons and the secondary electrons in extensive air shower (EAS) from vertical protons with different primary energies. The results show that the number of RREA electrons increases exponentially with the thickness of the thunderclouds increasing, and also increases exponentially with the electric field strength rising. After passing through the atmosphere with an electric field of –3000 V/cm and a thickness of 800 m, the number of secondary electrons in RREA process increases by approximately 3×10
4 times. The characteristic length of avalanche (
λ) decreases as the electric field strength increases. When the electric field is –1600 V/cm and –3000 V/cm, the
λ is approximately ~282 m and ~69 m, respectively. The energy spectrum of RREA electrons gradually softens with the increase of layer thickness and strength of electric field, and their average energy increases with the increase of electric field strength, when the thundercloud thickness exceeds 400 m, the mean energy of RREA electrons gradually stabilizes. When secondary particles pass through a thundercloud with an electric field strength of –3000 V/cm and a thickness of 800 m, the mean energy of RREA electrons is approximately 11.7 MeV. Through the Monte Carlo simulations, the RREA process, which is difficult to observe directly in the atmosphere, is successfully simulated. The simulation results provide important information for studying the characteristics of TGF source regions, offer clues for detecting downward TGF in ground-based experiments, and contribute to the research on the triggering mechanism of lightning in the atmosphere. In addition, our simulation results are expected to elucidate the relationship between TGF and lightning activity, promoting interdisciplinary research in the fields of atmospheric physics and cosmic ray physics.