Polystyrene (PS) composite nanofibers were successfully fabricated by embedding NaYF4: Eu3+ nanophosphor into the PS matrix via electrospinning. The photoluminescence spectra, surface morphology and crystal structure of nanofibers were characterized by photoluminescence spectroscopy, scanning electron microscopy, and X‐ray diffractometer, respectively. Stress‐induced α‐NaYF4: Eu3+ (cubic) to β‐NaYF4: Eu3+(hexagonal) structural phase transformation was observed in the nanofibers. The stress‐induced phase transformation provides enough space for tailoring the properties of novel nanostructures. The composite nanofibers exhibited blue emission with 239 nm excitation wavelength. The XRD pattern of espun nanofibers confirmed the successful incorporation of 5% NaYF4: Eu3+ nanophosphors into the PS matrix. Brilliant values of the chromaticity coordinates of the prepared photoluminescent nanofibers (PLNs) predict their possible use in blue solid‐state lighting applications.