Methods for gas control have been extensively developed for the monitoring of air quality, for gas leak control, for the development of 'electronic nose' systems, etc. Metal oxide gas sensors have been widely used in particular. However, apart from changes in the controlled gas concentration, changes in their parameters also depend on ambient conditions. The main impact comes from temperature and humidity. Therefore, the compensation of these disturbances is important for increasing the accuracy of concentration measurements of the controlled gases and the reliability of control. The present paper proposes a method for compensating the impact of temperature and humidity on gas sensor characteristics using artificial neural networks. This compensation method is applied to the control of methane concentration by gas sensors TGS813 and TGS2611. The results obtained confirm the applicability of this method.