In-field quality prediction in agricultural products is mainly based on near-infrared spectroscopy (NIR). However, initiatives applied to sugarcane quality are only observed under laboratory-controlled conditions. This study proposed a framework for NIR spectroscopy sensing to measure sugarcane quality during a real harvest operation. A platform was built to support the system composed of the NIR sensor and external lighting on the elevator of a sugarcane harvester. Real-time data were acquired in commercial fields. Georeferenced samples were collected for calibration, validation, and adjustment of the multivariate models by partial least squares (PLS) regression. In addition, subsamples of defibrated cane were NIR-acquired for the development of calibration transfer models by piecewise direct standardization (PDS). The method allowed the adjustment of the spectra collected in real time to predict the quality properties of soluble solids content (Brix), apparent sucrose in juice (Pol), fiber, cane Pol, and total recoverable sugar (TRS). The results of the relative mean square error of prediction (RRMSEP) were from 1.80 to 2.14%, and the ratio of interquartile performance (RPIQ) was from 1.79 to 2.46. The PLS-PDS models were applied to data acquired in real-time, allowing estimation of quality properties and identification of the existence of spatial variability in quality. The results showed that it is possible to monitor the spatial variability of quality properties in sugarcane in the field. Future studies with a broader range of quality attribute values and the evaluation of different configurations for sensing devices, calibration methods, and data processing are needed. The findings of this research will enable a valuable spatial information layer for the sugarcane industry, whether for agronomic decision-making, industrial operational planning, or financial management between sugar mills and suppliers.