A coating based FBG humidity sensor is developed for distributed humidity sensing. The sensitivity of the coated FBG is optimized by varying the chemical composition and the thickness of the coating. A sensitivity of ~2 pm/%RH and a rapid response are demonstrated. The composition of the coating can be adapted for sensing other chemical elements. For the design and modeling of the responsive polymer coatings, a toolbox is developed. Using this toolbox, sensors for sour gas like CO2 and H2S for the Oil&Gas industry are developed. The results match well with the prediction.