Flexibly applying abstract rules is a hallmark feature of executive functioning represented by prefrontal cortex (PFC) neurons. Prefrontal networks are regulated by the neuromodulator dopamine, but how dopamine modulates high-level executive functions remains elusive. In monkeys performing a rule-based decision task, we report that both dopamine D1 and D2 receptors facilitated rule coding of PFC neurons, albeit by distinct physiological mechanisms. Dopamine D1 receptor stimulation suppressed neuronal firing while increasing responses to the preferred rule, thereby enhancing neuronal rule coding. D2 receptor stimulation, instead, excited neuronal firing while suppressing responses to the nonpreferred rule, thus also enhancing neuronal rule coding. These findings highlight complementary modulatory contributions of dopamine receptors to the neuronal circuitry mediating executive functioning and goal-directed behavior.