ESPHome adds a relative-humidity correction for sensors warmed by the electronics around them. Correcting the temperature alone leaves the humidity reading wrong, because relative humidity changes with temperature rather than by a fixed percentage offset.

The filter uses the corrected temperature and its configured offset to recalculate humidity, keeping the result between zero and 100 percent. It supports Celsius and Fahrenheit readings; temperatures outside minus 40 to 50 degrees Celsius pass through unchanged with a warning.