Extracellular glutamate is elevated following brain ischemia or trauma and contributes to neuronal injury. We tested the hypothesis that magnesium sulfate (MgSO4, 3 mM) protects against metabolic failure caused by excitotoxic glutamate exposure. Rat cortical neuron preparations treated in medium already containing a physiological concentration of Mg(2+) (1 mM) could be segregated based on their response to glutamate (100 µM). Type I preparations responded with a decrease or small transient increase in oxygen consumption rate (OCR). Type II neurons responded with >50% stimulation in OCR, indicating a robust response to increased energy demand without immediate toxicity. Pre-treatment with MgSO4 improved the initial bioenergetic response to glutamate and ameliorated subsequent loss of spare respiratory capacity, measured following addition of the uncoupler FCCP, in Type I but not Type II neurons. Spare respiratory capacity in Type I neurons was also improved by incubation with MgSO4 or NMDA receptor antagonist MK801 in the absence of glutamate treatment. This finding indicates that the major difference between Type I and Type II preparations is the amount of endogenous glutamate receptor activity. Incubation of Type II neurons with 5 µM glutamate prior to excitotoxic (100 µM) glutamate exposure recapitulated a Type I phenotype. MgSO4 protected against an excitotoxic glutamate-induced drop in neuronal ATP both with and without prior 5 µM glutamate exposure. Results indicate that MgSO4 protects against chronic moderate glutamate receptor stimulation and preserves cellular ATP following treatment with excitotoxic glutamate.