Due to nutrient stress, which is an important constraint to the development of the global agricultural sector, it is now vital to timely evaluate plant health. Remote sensing technology, especially hyperspectral imaging technology, has evolved from spectral response modes to pattern recognition and vegetation monitoring. This study established a hyperspectral library of 14 NPK (nitrogen, phosphorus, potassium) nutrient stress conditions in rice. The terrestrial hyperspectral camera (SPECIM-IQ) collected 420 rice stress images and extracted as well as analyzed representative spectral reflectance curves under 14 stress modes. The canopy spectral profile characteristics, vegetation index, and principal component analysis demonstrated the differences in rice under different nutrient stresses. A transformer-based deep learning network SHCFTT (SuperPCA-HybridSN-CBAM-Feature tokenization transformer) was established for identifying nutrient stress patterns from hyperspectral images while being compared with classic support vector machines, 1D-CNN (1D-Convolutional Neural Network), and 3D-CNN. The total accuracy of the SHCFTT model under different modeling strategies and different years ranged from 93.92% to 100%, indicating the positive effect of the proposed method on improving the accuracy of identifying nutrient stress in rice.