Cognitive flexibility is required for decision-making behavior, and cognitive impairment can be observed in various psychiatric disorders. Nucleus accumbens (NAc) is one of key neural substrates for cognitive behavior in the cortico-basal ganglia circuit. Within the NAc, dopamine D1 and D2 receptor-expressing medium spiny neuron (D1-/D2-MSNs) in the direct and indirect pathways have been revealed to play important roles in controlling reward and aversive behavior, respectively. However, the collaborative role of NAc D1-/D2-MSNs in flexible cognitive behavior has been remained. In this study, using a visual discrimination task in mice, we assessed the role of NAc D1-/D2-MSNs in cue-guided reward-based decision-making behavior. Cell-type specific neuronal silencing and in vivo calcium imaging revealed NAc D1-/D2-MSNs to separately contribute to cue-guided reward-based decision-making behavior. Our findings indicate that homeostatic regulation of neural circuit mechanism within NAc underlies flexible cognitive behavior and the pathophysiology of psychiatric disorders.