Magnesium ion is known to selectively block the N-methyl-D-aspartate (NMDA)-induced responses and to have anticonvulsive action, neuroprotective effect and antinociceptive action in the behavioral test. In this study, we investigated the effect of Mg2 on the responses of dorsal horn neurons to cutaneous thermal stimulation and graded electrical stimulation of afferent nerves as well as to excitatory amino acids and also elucidated whether the actions of Ca2 and Mg2 are additive or antagonistic. Mg2 suppressed the thermal and C-fiber responses of wide dynamic range (WDR) cell without any effect on the A-fiber responses. When Mg2 was directly applied onto the spinal cord, its inhibitory effect was dependent on the concentration of Mg2 and duration of application. The NMDA- and kainate-induced responses of WDR cell were suppressed by Mg2, the NMDA-induced responses being inhibited more strongly. Ca2 also inhibited the NMDA-induced responses current-dependently. Both inhibitory actions of Mg2 and Ca2 were additive, while Mg2 suppressed the EGTA-induced augmentation of WDR cell responses to NMDA and C-fiber stimulation. Magnesium had dual effects on the spontaneous activities of WDR cell. These experimental findings suggest that Mg2 is implicated in the modulation of pain in the rat spinal cord by inhibiting the responses of WDR cell to noxious stimuli more strongly than innocuous stimuli.