In this paper, the mesoporous NiO nanowires (NWs) were synthesized by using SBA-15 silica as the hard templates with the nanocasting method, and then calcined from 550 to 750°C. X-ray diffraction, transmission electron microscopy (TEM), nitrogen adsorption/desorption isotherm and UV-vis spectrum were used to characterize the morphology, phase structure and microstructure of the as-prepared samples. All results indicated that the calcination temperature greatly affected crystallization degree and specific surface area of the as-prepared NiO NWs. And the crystallization degree increased and specific surface area decreased with the calcination temperature. The higher specific surface area created more active sites for the surface redox reaction, while the higher crystallization degree led to the wider bandgap and made the charge carriers transport easily. It was concluded that the calcination temperature of NiO NWs greatly affected the gas-sensing performance. The optimized results from the gas-sensing behavior indicated that NiO NWs-650 based sensor exhibited the highest sensitivity to ethanol for the suitable calcination temperature. Furthermore, NiO NWs-650 sensor exhibited a better selectivity to ethanol than n-hexane, methanol, acetone and formaldehyde.