The present study investigated the contributions of the medial prefrontal cortex and its major subdivisions, the dorsal anterior cingulate (ACd) and prelimbic-infralimbic (PL) cortices, to spatial working memory and inhibitory control processes. In experiment 1, excitotoxic lesions centred in the ACd or PL cortex did not affect acquisition of a nonmatching-to-place task in the T-maze with a retention interval of 10 s. However, the same reinforced alternation task was impaired by larger prefrontal lesions that combined ACd and PL cortices. In experiment 2, new animals were trained on a matching-to-place task in the T-maze that uses a rule counter to the animals' innate bias to alternate spontaneously. Now, discrete lesions of both the ACd and PL cortices impaired acquisition, but in different ways. Both animals with PL and with ACd lesions perseverated by nonmatching for more sessions than the controls, but only the PL animals also showed a more general increase in perseveration reflected in a further, extended period of applying an inefficient response rule (e.g. always turn right) and a deficit at reversing from matching to nonmatching. Acquisition of the matching-to-place task was also impaired by combined lesions of ACd and PL cortices. Overall, whilst spatial working memory processes appear to remain intact in those animals with discrete prefrontal lesions, the present findings provide strong evidence for the differential involvement of the prelimbic-infralimbic and anterior cingulate regions in providing behavioural flexibility.