One of the key features of addiction is the escalated drug intake. The neural mechanisms involved in the transition to addiction remain to be elucidated. Since abnormal neuronal activity within the subthalamic nucleus (STN) stands as potential general neuromarker common to impulse control spectrum deficits, as observed in obsessive-compulsive disorders, the present study recorded and manipulated STN neuronal activity during the initial transition to addiction (i.e., escalation) and post-abstinence relapse (i.e., re-escalation) in rats with extended drug access. We found that low-frequency (theta and beta bands) neuronal oscillations in the STN increase with escalation of cocaine intake and that either lesion or high-frequency stimulation prevents the escalation of cocaine intake. STN-HFS also reduces re-escalation after prolonged, but not short, protracted abstinence, suggesting that STN-HFS is an effective prevention for relapse when baseline rates of self-administration have been re-established. Thus, STN dysfunctions may represent an underlying mechanism for cocaine addiction and therefore a promising target for the treatment of addiction.