Humidity is one of the important parameters in the field of sensing, and the monitoring and control of humidity is used in many applicationssuch as agriculturecultural relics protectionenvironmental safety, and pharmaceutical engineering. Since traditional electronic humidity sensors are mainly based on capacitance or resistivity measurements, which are more susceptible to electromagnetic interference. Moreoverunder high humidity environment, water vapor will corrode the circuit boardwhich is a great test for the long-term stability of electronic humidity sensors. Compared with traditional humidity sensors, fiber optic humidity sensors have the advantages of corrosion resistance, light weightcan be operated remotely, not subject to electromagnetic interference, etc., and have been widely studied in recent years. Among them, U-shaped microfiber has the advantages of small size, low fabrication costhigh sensitivity, etc., which has a broad prospect in the field of humidity measurement. In this paper, a U-shaped microfiber humidity sensor based on Polyvinyl alcohol (PVA) coating is proposed, and the single-mode optical fiber is pulled into micron- sized microfiber by fiber optic melting and cone pulling machine, and the microfiber with different diameters can be prepared by changing the flame temperature and cone pulling speed, etc. PVA is a strong hydrophilic material, and its refractive index changes with the humidity of the surrounding environment. Due to the high adherence of PVA on the surface of silica, it can be used for the measurement of humidity in a wide range of applications. PVA has high adhesion on the surface of silica, so it can be easily coated on the surface of optical fiber. Because of these special properties of PVA, combining PVA with ultrafine optical fiber can be used to measure humidity. Using the drop coating method, the PVA solution is uniformly coated on the surface of the optical fiber, and the coated ultrafine optical fiber is passed through a homemade mold, which is made of three capillary glass tubes, and the ultrafine optical fiber is fixed into a U-shape by means of UV photoresist and ultraviolet lamp. The paper prepared three humidity sensors, which were used to study the effect of coating thickness on the humidity of the sensors. It was found that the humidity sensitivity of the U-shaped sensors was extremely low when they were not coated with PVA; after coating with PVA, the sensitivity of the sensors increased with the increase of the coating thickness. At the same time, the thicker the coating the greater the loss of the sensor, and it will lead to a longer fabrication time of the sensor, which will cause the PVA droplets on the dropper to evaporate, thus affecting the uniformity of the coating. Therefore, there is a need to select a suitable coating thickness. In order to investigate the effect of the diameter of the waist zone on the humidity of the sensor, two different diameters of the sensor are prepared in this paper. The experimental results found that the smaller the diameter of the waist region, the higher the sensitivity of the sensor, which is due to the fact that the smaller the waist diameter of the ultrafine optical fiber coupled with the external environment the stronger the swift fieldwhich strengthens the interaction between them. The experimental results show that the sensor prepared in this paper has a high humidity sensitivity of 146.1 pm/%RH in the detection range of 34% RH similar to 90% RH. In the humidity measurement experiments, the fluctuation of the temperature will have a certain effect on the experimental results. This is because temperature changes the physicochemical properties of PVA film and U-shaped microfiber, such as changes in refractive index and expansion. Therefore, it is an important work to explore the effect of temperature on the crosstalk of the sensor. Temperature experiments show that the temperature sensitivity of the sensor is 15.8/degrees C in the range of 40 degrees C similar to 80 degrees C, and its crosstalk sensitivity is 0.108% RH/degrees C, which is much lower than the humidity sensitivity, so the temperature has less effect on this sensor. The sensor designed in this paper has a simple preparation process, high sensitivity, easy to carry, low cost, less influence of temperature crosstalk, which has a wide range of applications in the field of humidity detection.