Successful behavior requires selection and preferred processing of relevant sensory information. The cortical representation of relevant sensory information has been related to neuronal oscillations in the gamma frequency band. Pain is of invariably high behavioral relevance and, thus, nociceptive stimuli receive preferred processing. Here, by using magnetoencephalography, we show that selective nociceptive stimuli induce gamma oscillations between 60 and 95 Hz in primary somatosensory cortex. Amplitudes of pain-induced gamma oscillations vary with objective stimulus intensity and subjective pain intensity. However, around pain threshold, perceived stimuli yielded stronger gamma oscillations than unperceived stimuli of equal stimulus intensity. These results show that pain induces gamma oscillations in primary somatosensory cortex that are particularly related to the subjective perception of pain. Our findings support the hypothesis that gamma oscillations are related to the internal representation of behaviorally relevant stimuli that should receive preferred processing.