Naltrexone is a medication primarily used in the management of alcohol and opioid dependence. It is a competitive opioid receptor antagonist, meaning it blocks the effects of opioids by occupying the same receptor sites without activating them. This action helps in reducing cravings and preventing relapse in individuals recovering from substance use disorders.