The detection of partial discharge through analysis of SF6 gas components in gas-insulated switchgear, is significant for the diagnosis and assessment of the operating state of power equipment. The present study proposes the use of a TiO2 nanotube array sensor for detecting the SF6 decomposition product SO2, and the application of the anodic oxidation method for the directional growth of highly ordered TiO2 nanotube arrays. The sensor response of 10–50 ppm SO2 gas is tested, and the sensitive response mechanism is discussed. The test results show that the TiO2 nanotube sensor array has good response to SO2 gas, and by ultraviolet radiation, the sensor can remove attached components very efficiently, shorten recovery time, reduce chemical poisoning, and prolong the life of the components.