A reading is only as good as its last check
When a sensor is new, its readings are close to the true value within the limits on its data sheet. Over months and years, that closeness gradually erodes. Nothing dramatic happens: the numbers keep arriving, still plausible and still neatly formatted. That is exactly why drift is dangerous. A sensor that fails completely is obvious. One that is slowly wrong can quietly mislead decisions.
Accuracy, drift and calibration in plain terms
- Accuracy is how close a reading is to the true value at a given moment.
- Drift is the slow change in a sensor’s output over time when the real value has not changed.
- Calibration is the process of comparing a sensor with a trusted reference and adjusting for the difference.
The meaning of the terms used on a data sheet is explained further in the article on sensor specifications.
Why readings wander
There is rarely a single cause. Common contributors include:
- Aging of materials. The sensing element changes slowly. Polymers absorb contaminants, metal films oxidize, and chemical sensing layers are consumed or degraded.
- Contamination. Dust, oil, salt, condensation or biological growth coat the sensing surface. Particle sensors and humidity sensors are especially exposed.
- Thermal stress. Repeated heating and cooling or a single exposure to extreme heat can permanently shift a component.
- Mechanical stress. Vibration, shocks or strain on a mounting can change a pressure or force sensor’s zero point.
- Electronics. Reference voltages, resistors and amplifiers have their own temperature and aging behavior, and a drooping battery can alter readings in poorly designed circuits.
- Environment. Sunlight on an outdoor housing, or a heat source added near an indoor sensor, changes what it sees. This is not drift in the strict sense, but it looks the same in the data.
- Exposure. Some sensors shift after contact with high humidity or strong chemicals, then partially recover.
Drift rates differ greatly by type. Some temperature sensors are very stable, while chemical gas sensors may need attention far more often. The documentation sometimes gives a typical drift per year, which is a useful starting point for planning.
Offset and gain errors
Two simple models describe many calibration problems.
An offset error shifts all readings by the same amount. Suppose, hypothetically, a temperature sensor reads 20.6 when a trusted thermometer reads 20.0 and does so across the range. Subtracting 0.6 corrects it.
A gain error (or slope error) means the error grows with the value. A sensor might be right at 0 degrees but read 1 degree high at 100 degrees. A correction then must scale the readings as well as shift them.
Real sensors can also be nonlinear, with a curve rather than a line, which needs more reference points to correct.
How calibration works
One-point calibration
You compare the sensor against a reference at a single known condition and correct the offset. This is quick and corrects the most common problem, but it assumes the gain is already right.
Two-point calibration
You compare at two conditions, preferably near the low and high ends of the working range, and correct both offset and gain. Using the earlier style of hypothetical numbers: if the sensor reads 2.0 where the true value is 0.0, and reads 102.0 where the true value is 100.0, the shift is a constant 2.0, so subtracting 2.0 fixes it. If instead it read 1.0 and 103.0, the true change of 100 appears as 102, so the scale factor is 100 divided by 102, about 0.98, applied after removing the offset of 1.0. Checking such arithmetic by hand with your own values is a good habit before loading it into a device.
Reference conditions
References should be better than the device under test, typically by a comfortable margin. For temperature, a reference thermometer with a calibration certificate is the straightforward option. Some humidity checks use sealed containers with salt solutions that hold a known humidity at a given temperature, though results depend on careful technique. For gas sensors, certified calibration gas is used, and handling it can have safety considerations. Many gas and air quality sensors are best returned to a service that does this properly.
Calibrating in practice
- Before and after. Record the readings before adjusting, so you learn how much the sensor had drifted. That history shows how often calibration is needed.
- Stable conditions. Let both sensors settle in the same environment, with the reference placed close by, and wait for response times to pass.
- Documentation. Log the date, reference used, and correction applied. Calibration without records is hard to trust later.
- Storing corrections. Corrections can live in firmware, in a configuration file, or in the back end that receives the data. Keeping them in the back end allows adjustments without touching the field device, though the link between device and correction must be tracked carefully.
- Intervals. Choose a schedule from the drift rate and how costly an error would be. Annual checks are common in many fields, but the right interval varies.
Calibration at scale
Visiting hundreds of devices is expensive. Several strategies reduce the effort:
- Cross-checking neighbors. Comparing similar sensors in the same area can reveal one that has wandered, a technique related to anomaly detection.
- Spot checks. Calibrate a sample of devices and infer fleet behavior.
- Swap programs. Replace sensors with freshly calibrated ones on a rotation.
- Self-checks. Some designs include a known reference condition, or compare two redundant sensors.
- Monitoring data quality. Flat lines, sudden steps and out-of-range values are cues that a device needs attention, which fits with the practices on data quality in sensor streams.
Know the limits
Calibration cannot repair a damaged or unsuitable sensor, and it does not remove random noise. It also cannot make a cheap part as good as a better one, because it corrects systematic errors but not unpredictable ones. If the sensor drifts faster than you can calibrate it, or if its readings feed a decision where an error would matter, the sensible response is a different sensor or a higher level of verification.