Objective: To examine event-related brain potentials (ERPs) in Multiple Sclerosis (MS) during a visual n-back working memory (WM) task, and test the hypothesis that compensatory brain function may be associated with variance in task performance in MS patients. Methods: Midline ERPs for 25 MS patients and 18 HCs were obtained for a visual n-back task that placed increasing demands on WM. N-back behavioral measures and neuropsychological performance measures of WM were also obtained. Results: MS patients had slower reaction times (RTs) than HCs during the n-back task. Accuracy on the n-back and on neuropsychological tests did not differ between groups. P3 ERP amplitude decreased for both groups as WM demand increased. MS patients had lower overall P1 and P3 amplitudes compared to HCs. In MS, anteriorization of P3 amplitude was associated with better n-back performance. P1 and P3 amplitudes were also related to neuropsychological test performance in MS. Conclusions: MS patients had reduced ERP amplitude compared to HCs during the n-back, and changes in ERP anterior-posterior midline amplitude distribution in MS were associated with cognitive performance. (C) 2017 International Federation of Clinical Neurophysiology. Published by Elsevier Ireland Ltd. All rights reserved.