To solve the problem of the adverse influence of rainfall spatiotemporal heterogeneity on flood peak in the basin under natural conditions, a flood frequency analysis method is proposed based on the combination of RainyDay and SWAT model. Taking the Dongjiang River Basin as an example, the design rainfall of the basin under different return periods is proposed using RainyDay model, and then reconstructed into six rainfall scenarios with different temporal and spatial heterogeneity. Finally, the above scenarios are used as input in the SWAT model to quantitatively simulate the response of the flood peaks of the basin to the spatial and temporal heterogeneity of rainfall under natural conditions. It is found that when the difference of temporal heterogeneity between two scenarios is narrowing down to zero, the difference between the flood peaks increases with the increase of spatial heterogeneity, with the maximum value exceeding 700 m3/s and the average value exceeding 300 m3/s. Whereas when the difference of spatial heterogeneity between two scenarios is narrowing down to zero, the difference between the flood peaks increases with the increase of temporal heterogeneity, with the maximum value approaching 700 m3/s and the the average value exceeding 200 m3/s. Under the same return period, the flood peaks generated by the scenarios with high spatiotemporal heterogeneity of rainfall are higher than that of the other scenarios, and the maximum difference between the flood peaks exceeds 1, 000 m3/s. The influence of spatial heterogeneity of rainfall on flood peaks is more significant than that of temporal heterogeneity.