Despite meloxicam’s many benefits, it will cause many drawbacks if the meloxicam release rate is not controlled. Accordingly, we introduced a technique based on the electrospinning process to control the release rate and also to reduce side effects. For this purpose, different nanofibers were used as drug couriers. Nanofibers were prepared using polyurethane, polyethylene glycol, and light curable poly (ethylene glycol) diacrylate (PEGDA) by electrospinning. In fact, light curable poly (ethylene glycol) diacrylate (PEGDA) was synthesized as a hydrophilic functional group. Next, PEGDA and polyurethane were used simultaneously to fabricate the drug carrier nanofiber in a single processing step, and the electrospinning apparatus was equipped with a blue light source for in-situ photopolymerization during the electrospinning process. The molecular structures of nanofibers and PEGDA were investigated by FT-IR, 1H NMR, 13C NMR, SEM, TEM, XRD, and DSC analyses. Finally, we reduced in vitro drug release to 44% within ten hours, while the minimum release of meloxicam from the tablet was 98%.