Iberian ham is a highly appreciated product and according to Spanish legislation different labels identify different products depending on the genetic purity. Consequently, “100% Iberian” ham from purebred Iberian animals is more expensive than “Iberian” ham from Iberian x Duroc crosses. The hypothesis of this study was that to avoid labelling fraud it is possible to distinguish the breed (Iberian or Iberian x Duroc) of acorn-fed pigs of Iberian ham without any prior preparation of the sample by using spectroscopy that is a rapid and reliable technology. Moreover, portable devices which can be used in situ could provide similar results to those of benchtop equipment. Therefore, the spectra of the 60 samples (24 samples of 100% Iberian ham and 36 samples of Iberian x Duroc crossbreed ham) were recorded only for the fat, only for the muscle, or for the whole slice with two benchtop near-infrared (NIR) spectrometers (Büchi NIRFlex N-500 and Foss NIRSystem 5000) and five portable spectrometers including four portable NIR devices (VIAVI MicroNIR 1700 ES, TellSpec Enterprise Sensor, Thermo Fischer Scientific microPHAZIR, and Consumer Physics SCiO Sensor), and one RAMAN device (BRAVO handheld). The results showed that, in general, the whole slice recording produced the best results for classification purposes. The SCiO device showed the highest percentages of correctly classified samples (97% in calibration and 92% in validation) followed by TellSpec (100% and 81%). The SCiO sensor also showed the highest percentages of success when the analyses were performed only on lean meat (97% in calibration and 83% in validation) followed by microPHAZIR (84% and 81%), while in the case of the fat tissue. Raman technology showed the best discrimination capacity (96% and 78%) followed by microPHAZIR (89% and 81%). Therefore, spectroscopy has proved to be a suitable technology for discriminating ham samples according to breed purity; portable devices have been shown to give even better results than benchtop spectrometers.