Chronic pain and depression are frequently comorbid and ketamine has emerged as a potentially promising therapy. But the molecular mechanisms underlying comorbid depressive symptoms in chronic pain and ketamine antidepressant effects remain elusive. Here, we show that Tiam1 orchestrates synaptic structural and functional remodeling in anterior cingulate cortex (ACC) neurons via actin cytoskeleton reorganization and synaptic NMDAR stabilization. This Tiam1-coordinated synaptic plasticity underpins ACC hyperactivity and drives chronic pain-induced depressive-like behaviors. Ketamine induces sustained antidepressant effects in chronic pain by blocking Tiam1-mediated synaptic structural and functional plasticity in ACC neurons. Our results reveal Tiam1 as a key factor in the pathophysiology of chronic pain-induced depression and in the sustained antidepressant effects of ketamine in ACC neurons.