Variable selection is a highly effective approach to improve model performance when analyzing and modeling data from near-infrared spectroscopy. Moving window partial least squares (MWPLS), a well-known and classical wavelength interval selection algorithm, was widely used in the field of near-infrared spectroscopy. However, it has gradually faded from the spotlight due to its limitations. In this study, a modified MWPLS method called interval interaction moving window partial least squares (iMWPLS), was proposed to improve some limitations of MWPLS, including the lack of consideration for the combination effects of variables, the tendency to select redundant wavelength intervals, and the need for artificial intervention. By utilizing the framework of MWPLS, it could iteratively search, test, and add the intervals with the local minimum errors to the set of basic intervals. The method has high sensitivity to the combination effects of variables and enables accurate selection of intervals. Three NIR datasets, including corn starch, pharmaceutical tablets, and soil dataset were tested to evaluate the performance of iMWPLS. The results show that iMWPLS has better performance than other seven wavelength selection methods, including MWPLS, SEPA-MWPLS, fiPLS, biPLS, siPLS, iVISSA, and iRF.