COVID-19 is reported to have been brought under control in China. To understand the COVID-19 outbreak in China and provide potential lessons for other parts of the world, in this study we apply a mathematical model with multiple datasets to estimate the transmissibility of the SARS-CoV-2 virus and the severity of the illness associated with the infection, and how both were affected by unprecedented control measures. Our analyses show that before 19th January 2020, 3.5% (95% CI 1.7-8.3%) of infected people were detected; this percentage increased to 36.6% (95% CI 26.1-55.4%) thereafter. The basic reproduction number (R0) was 2.33 (95% CI 1.96-3.69) before 8th February 2020; then the effective reproduction number dropped to 0.04(95% CI 0.01-0.10). This estimation also indicates that control measures taken since 23rd January 2020 affected the transmissibility about 2 weeks after they were introduced. The confirmed case fatality rate is estimated at 9.6% (95% CI 8.1-11.4%) before 15 February 2020, and then it reduced to 0.7% (95% CI 0.4-1.0%). This shows that SARS-CoV-2 virus is highly transmissible but may be less severe than SARS-CoV-1 and MERS-CoV. We found that at the early stage, the majority of R0 comes from undetected infectious people. This implies that successful control in China was achieved through reducing the contact rates among people in the general population and increasing the rate of detection and quarantine of the infectious cases.