Pure ZnO and carbon-doped ZnO hollow spheres were successfully synthesized by a hydrothermal-calcination process. The doping content of carbon in ZnO was controlled by different calcination temperatures at 500 ℃ and 600 ℃ (named as ZnO-500 and ZnO-600). Systematic material characterization indicates that mesoporous ZnO hollow spheres are featured in abundant defects induced by in-situ carbon doping. Used as gas sensing materials, the response of ZnO-600 towards 200 ppm dimethylamine (83.6) is 28.6 times and 2.5 times higher than that of Pure ZnO (2.9) and ZnO-500 (32.8) at the optimum operating temperature of 240 ℃. Remarkably, the response of ZnO-600 toward 1 ppm dimethylamine is as high as 7.2, and simultaneously the limit of detection is as low as 108 ppb. In addition, ZnO-600 hollow spheres hold excellent gas-sensing performance in response-recovery speed, selectivity, repeatability, long-term stability, and water resistance towards dimethylamine. The boosted dimethylamine sensing performance of ZnO-600 is mainly attributed to synergistic effects of the unique mesoporous microstructure and rich defects induced by in-situ carbon doping. This work provides a promising material for dimethylamine detection, the properties of which can be improved for practical applications in the future. Furthermore, this contribution gives new insights into nonmetal-doped metal oxide nanostructures for high-performance gas sensors via surface defect control.