In this paper, Zn1-xInxSnO3 cubes were synthesized by a simple co-precipitation method, and the morphology and structure of the samples were characterized by various techniques. The results show that Zn1-xInxSnO3 has a regular cube structure with a size range of 900–1000 nm. It is obtained by N2 absorption and BET calculation that doping In element improves the specific surface area of the material, promotes the reaction between the measured gas and the gas-sensing material, and thus improves the gas-sensing property of the material. The gas-sensing test results indicate that contrasted with the pure ZnSnO3 sample, the optimal operating temperature of the Zn1-xInxSnO3 (ZISO) sample is reduced (200 °C), and the response value is improved. Especially, Zn0·95In0·05SnO3 (ZISO-5) showed a significantly improved response to 100 ppm formaldehyde gas at the optimum operating temperature of 200 °C, which provided rapid, real-time and efficient technical support for formaldehyde detection. In addition, we also discuss the gas-sensing mechanism of the Zn1-xInxSnO3 cube obtained by In doping to formaldehyde. This study provides technical support and theoretical basis for the optimization of gas-sensing property of ZnSnO3 gas-sensing materials.