Dieting induces depression and anxiety among other emotional symptoms. Animal models indicate that repeated access to palatable foods such as sugar induces depression and anxiety-like behavior when the food is no longer available. However, the neurobiological mechanisms of how dietary restriction influences mood have not been fully understood. We used the two-bottle sucrose choice paradigm as an overeating and withdrawal model. Withdrawal after lengthy sucrose overeating elicited depression and anxiety-like behavior, which was reversed by sucrose reinstatement. In the nucleus accumbens (NAc) of sucrose withdrawal animals, dopamine levels and cAMP response element binding protein (CREB) activity were significantly reduced, while the inwardly rectifying K+ channel, Kir2.1, was significantly elevated. In addition, overexpression of Kir2.1 selectively in neurons expressing dopamine D1 receptors was sufficient to induce negative mood-linked behavior in the absence of sucrose overeating experience. As elevated K+ channels reduce neuronal excitability, a sucrose withdrawal-induced increase in Kir2.1 expression is able to decrease NAc activity, which provides a cellular basis for depression and anxiety-like behavior in animals.