The conflict-monitoring hypothesis posits that anterior cingulate cortex (ACC) monitors conflict in information processing and recruits dorsolateral prefrontal cortex (DLPFC) to resolve competition as needed. We used fMRI to test this prediction directly in the context of a task-switching paradigm, in which subjects responded to the color or the motion of a visual stimulus. Conflict was indexed in terms of the product of activities in areas specialized for color or motion processing on a trial-by-trial basis. Here, we report that ACC and posterior parietal cortex (PPC) were sensitive to distinct forms of conflict, at the level of the response and the stimulus representation, respectively. Activity in PPC preceded increased activity in DLPFC and predicted enhanced behavioral performance on subsequent trials. These findings suggest that ACC and PPC may act in concert to detect dissociable forms of conflict and signal to DLPFC the need for increased control.