Cocaine (from French: cocaïne, from Spanish: coca, ultimately from Quechua: kúka) is a tropane alkaloid that acts as a central nervous system (CNS) stimulant. As an extract, it is mainly used recreationally, and often illegally for its euphoric and rewarding effects. It is also used in medicine by Indigenous South Americans for various purposes and rarely, but more formally, as a local anaesthetic or diagnostic tool by medical practitioners in more developed countries. It is primarily obtained from the leaves of two Coca species native to South America: Erythroxylum coca and E. novogranatense. After extraction from the plant, and further processing into cocaine hydrochloride (powdered cocaine), the drug is administered by being either snorted, applied topically to the mouth, or dissolved and injected into a vein. It can also then be turned into free base form (typically crack cocaine), in which it can be heated until sublimated and then the vapours can be inhaled.

Cocaine stimulates the reward pathway in the brain. Mental effects may include an intense feeling of happiness, sexual arousal, loss of contact with reality, or agitation. Physical effects may include a fast heart rate, sweating, and dilated pupils. High doses can result in high blood pressure or high body temperature. Onset of effects can begin within seconds to minutes of use, depending on method of delivery, and can last between five and ninety minutes. As cocaine also has numbing and blood vessel constriction properties, it is occasionally used during surgery on the throat or inside of the nose to control pain, bleeding, and vocal cord spasm.

Cocaine crosses the blood–brain barrier via a proton-coupled organic cation antiporter and (to a lesser extent) via passive diffusion across cell membranes. Cocaine blocks the dopamine transporter, inhibiting reuptake of dopamine from the synaptic cleft into the pre-synaptic axon terminal; the higher dopamine levels in the synaptic cleft increase dopamine receptor activation in the post-synaptic neuron, causing euphoria and arousal. Cocaine also blocks the serotonin transporter and norepinephrine transporter, inhibiting reuptake of serotonin and norepinephrine from the synaptic cleft into the pre-synaptic axon terminal and increasing activation of serotonin receptors and norepinephrine receptors in the post-synaptic neuron, contributing to the mental and physical effects of cocaine exposure.

A single dose of cocaine induces tolerance to the drug’s effects. Repeated use is likely to result in addiction. Addicts who abstain from cocaine may experience craving and drug withdrawal symptoms, with depression, decreased libido, decreased ability to feel pleasure, and fatigue being most common. Use of cocaine increases the overall risk of death, and intravenous use potentially increases the risk of trauma and infectious diseases such as blood infections and HIV through the use of shared paraphernalia. It also increases risk of stroke, heart attack, cardiac arrhythmia, lung injury (when smoked), and sudden cardiac death. Illicitly sold cocaine can be adulterated with fentanyl, local anesthetics, levamisole, cornstarch, quinine, or sugar, which can result in additional toxicity. In 2017, the Global Burden of Disease study found that cocaine use caused around 7,300 deaths annually.