ObjectivesThe internet data is an essential tool for reflecting public attention to hot issues. This study aimed to use the Baidu Index (BDI) and Sina Micro Index (SMI) to confirm correlation between COVID-19 case data and Chinese online data (public attention). This could verify the effect of online data on early warning of public health events, which will enable us to respond in a more timely and effective manner.MethodsSpearman correlation was used to check the consistency of BDI and SMI. Time lag cross-correlation analysis of BDI, SMI and six case-related indicators and multiple linear regression prediction were performed to explore the correlation between public concern and the actual epidemic.ResultsThe public's usage trend of the Baidu search engine and Sina Weibo was consistent during the COVID-19 outbreak. BDI, SMI and COVID-19 indicators had significant advance or lag effects, among which SMI and six indicators all had advance effects while BDI only had advance effects with new confirmed cases and new death cases. But compared with the SMI, the BDI was more closely related to the epidemic severity. Notably, the prediction model constructed by BDI and SMI can well fit new confirmed cases and new death cases.ConclusionsThe confirmed associations between the public's attention to the outbreak of COVID and the trend of epidemic outbreaks implied valuable insights into effective mechanisms of crisis response. In response to public health emergencies, people can through the information recommendation functions of social media and search engines (such as Weibo hot search and Baidu homepage recommendation) to raise awareness of available disease prevention and treatment, health services, and policy change.