Since the outbreak of COVID-19, wearing masks, vaccinations, and maintaining a safe distance has become social behaviors advocated by the government and widely adopted by the public. At the same time, unpredictable natural disaster risks brought by extreme climate change compound difficulties during epidemics and cause systemic risks that influence the existing pattern of epidemic prevention. Therefore, it is necessary to explore the effect of natural disaster risk caused by climate change on the response to outbreaks in the context of the COVID-19 epidemic. This study will focus on individual-level epidemic prevention behaviors, taking as an example the significant risk of severe destructive flooding caused by heavy rains in Henan, China, on July 20, 2021, which claimed 398 lives, to explore the effect of floods on the preventive behaviors of residents in the hardest hit areas against COVID-19. Through the multi-stage stratified random sampling of the affected residents in Zhengzhou, Xinxiang, Hebi, Luoyang, Anyang, and other cities in Henan Province, 2,744 affected people were surveyed via questionnaires. Through the linear regression model and moderating effect analysis, the study found that after floods, the individual's flood risk perception and response behaviors significantly correlated with the individual's prevention behaviors against COVID-19. Specifically, both flood risk perception and response behaviors strengthened the individual's prevention behaviors. Furthermore, the study also found that community risk preparation behavior and social capital can moderate the above relationship to a certain extent. The research can guide risk communication under the compound risk scenario and prevent risky public behavior under the consistent presence of COVID-19 in the community.