The spectra for first return strokes of cloud-to-ground lightning discharge were obtained by a slit-less spectrograph at the Qinghai plateau of China. In this paper, the effect of the observation distance on diagnosis results of channel temperature was calculated and discussed by applying the Beer-Lambert law and considering the attenuation of spectral line intensity in transmission. Results show that there is some difference in channel temperature obtained at different observation distances. The observation distance is further enlarged, then the temperature obtained will be lower. Furthermore, at further increased distance we take observation, the bigger the error will be. So the correction for the temperature is more important for longer observation distance. According to our calculation and analysis, a semi-empirical formula has been obtained, which shows a relationship between the lightning channel temperature and the observation distance. The influence of the observation distance on lightning channel temperature could be eliminated by using the semi-empirical formula.