The detection of nutritional compounds is usually performed through laboratory analysis, which requires extensive planning, time, cost, and effort. Alternatively, visible/near-infrared (Vis/NIR) spectroscopy can be used to determine the presence of nutritional compounds in real-time. This study aimed to investigate the potential application of the Vis/NIR spectroscopy in the quantitative detection of nutritional compounds in green ‘Ratuni UNPAD’ cayenne pepper. Prior to the model development, 80 samples were prepared for the calibration set, while another 40 samples were provided for the prediction set. Subsequently, the parameters used to calculate the model accuracy included the coefficient of correlation in calibration set (Rcal), coefficient of correlation in prediction set (Rpred), root mean square error of calibration set (RMSEC), root mean square error of prediction set (RMSEP) and the ratio of prediction to deviation (RPD). The experimental results involving the total carotenoids showed good model indicators with Rcal, Rpred, RMSEC, RMSEP, and RPD at 0.94, 0.89, 1.29, 1.75, and 2.21, respectively. Additionally, the analysis of the water content indicated Rcal, Rpred, RMSEC, RMSEP, and RPD values of 0.86, 0.85, 0.59, 0.61, and 1.90, respectively, while that of capsaicin had Rcal, Rpred, RMSEC, RMSEP, and RPD values of 0.89, 0.90, 117.82, 115.62, and 2.29, respectively. The results showed that Vis/NIR spectroscopy can be used to detect the nutritional compounds in green ‘Ratuni UNPAD’ cayenne pepper based on total carotenoids, water content, and capsaicin parameters.