A method of calibrating an optical absorption gas sensor for detecting an analyte gas, the sensor comprising a gas sample receiving chamber, a light emitting diode (LED) and a photodiode having an output signal sensitive to the amount of light received by the photodiode, the method comprising measuring the photodiode output signal at a first concentration and a different second concentration of the analyte gas within the gas sample receiving chamber, and thereby determining photodiode calibration data and determining LED calibration data based on the measured photodiode output signal at the first concentration and the different second concentration of the analyte gas within the gas sample receiving chamber.