Abstract. Ultraviolet (UV) radiation is closely related to health; however, limited measurements have hindered further investigation of its health effects in China. Machine learning algorithms have been widely used to predict environmental factors with high accuracy, but a limited number of studies have implemented it for UV radiation. The main aim of this study is to develop a UV radiation prediction model using the random forest approach and predict the UV radiation with a daily and 10 km resolution in mainland China from 2005 to 2020. The model was developed with multiple predictors, such as UV radiation data from satellites as independent variables and ground UV radiation measurements from monitoring stations as the dependent variable. Missing satellite-based UV radiation data were obtained using the 3 d moving average method. The model performance was evaluated using multiple cross-validation (CV) methods. The overall R2 and root mean square error between measured and predicted UV radiation from model development and model 10-fold CV were 0.97 and 15.64 W m−2 and 0.83 and 37.44 W m−2 at the daily level, respectively. The model that incorporated erythemal daily dose (EDD) retrieved from the Ozone Monitoring Instrument (OMI) had a higher prediction accuracy than that without it. Based on predictions of UV radiation at the daily level, 10 km spatial resolution, and nearly 100 % spatiotemporal coverage, we found that UV radiation increased by 4.20 %, PM2.5 levels decreased by 48.51 %, and O3 levels increased by 22.70 % from 2013–2020, suggesting a potential correlation among these environmental factors. The uneven spatial distribution of UV radiation was associated with factors such as latitude, elevation, meteorological factors, and season. The eastern areas of China pose a higher risk due to both high population density and high UV radiation intensity. Using a machine learning algorithm, this study generated a gridded UV radiation dataset with extensive spatiotemporal coverage, which can be utilized for future health-related research. This dataset is freely available at https://doi.org/10.5281/zenodo.10884591 (Jiang et al., 2024).