Have you looked at the SHT31 and Si7021 sensors with membrane/PTFE filter?
The versions with membrane/PTFE filter are rated for IP67.
SHT31 was previously mentioned in: The WORKBENCH part 1
SHT31
-
Sensirion SHT3x product page
Si7021
-
Silicon Labs Si7021 product page
Sensor modules based on Si7021 with filter are available on AliExpress:
A possible option to protect the rest of the electronics from moist and water is by covering (painting or spraying) it with (the sensor itself should not be covered of course):
-
Liquid Electrical Tape (LET)
Manufacturers: Star brite, Permatex, Performix. -
Plasti DIP
Similar to LET (but possibly thicker).
For electronics a thin layer better preserves cooling properties.Performix and Plasti DIP also have spray versions.
For reliable measurements you will still need a proper housing that protects the sensor from rain and (direct) sun light and that allows for sufficient ventilation. E.g. something like:
A compact DIY outdoor weather station could be build with a Heltec CubeCell HTCC-AB01 board + Si7021 module + BMP280 module and above plastic outer shield. The CubeCell board supports Li-ion/LiPo batteries and solar panel charging and uses only 8.5 uA in deep sleep when powered by Li-ion or LiPo battery.
Sensor Tests
Some tests with above sensors: http://www.kandrsmith.org/RJS/Misc/hygrometers.html