Porous materials have become ideal candidates for the creation of optical sensors that are able to reach extremely high sensitivities, due to both the possibility to infiltrate the target substances on them and to their large surface-to-volume ratio. In this work, we present a new alternative for the creation of porous optical sensors based on the use of polymeric nanofibers (NFs) layers fabricated by electrospinning. Polyamide 6 (PA6) NFs layers with average diameters lower than 30 nm and high porosities have been used for the creation of Fabry-Pérot optical sensing structures, which have shown an experimental sensitivity up to 1060 nm/RIU (refractive index unit). This high sensitivity, together with the low production cost and the possibility to be manufactured over large areas, make NFs-based structures a very promising candidate for the development of low-cost and high performance optical sensors