Gamma band oscillations (GBOs) elicited by transient nociceptive stimuli are one of the most promising biomarkers of pain across species. Still, whether these GBOs reflect stimulus encoding in the primary somatosensory cortex (S1) or nocifensive behavior in the primary motor cortex (M1) is debated. Here we recorded neural activity simultaneously from the brain surface as well as at different depths of the bilateral S1/M1 in free-moving male rats receiving nociceptive stimulation. GBOs measured from superficial layers of S1 contralateral to the stimulated paw not only had the largest magnitude, but also showed the strongest temporal and phase coupling with epidural GBOs. Also, spiking of superficial S1 interneurons had the strongest phase coherence with epidural GBOs. These results provide the first direct demonstration that scalp GBOs, one of the most promising pain biomarkers, reflect neural activity strongly coupled with the fast-spiking of interneurons in the superficial layers of the S1 contralateral to the stimulated side. Our results provide the direct demonstration that nociceptive-induced gamma band oscillations (GBOs) measured at population level, one of the most promising biomarker of pain perception, reflect neural activity coupled with the spike firing of interneurons in the superficial layers of the primary somatosensory cortex (S1) contralateral to the side of nociceptive stimulation. These results conclusively solve the ongoing debate about whether nociceptive-induced GBOs recorded with scalp electroencephalogram (EEG) or epidurally reflect stimulus encoding in the S1 or nocifensive behavior in the primary motor cortex (M1), and will therefore influence how experiments in pain neuroscience will be designed and interpreted.