Pharmaceutical opioids are intravenously or orally administered analgesics. While they are effective in relieving chronic and acute pain, their narrow window of therapeutic use contributes to the high occurrence of abuse. The associated abuse of this family of drugs can be correlated to the increase in dependency, overdose, and death of users. The negative effects of opioids extend beyond the physical and psychological effects experienced by the user to their unregulated synthesis and sale, which contribute to socioeconomic challenges and are a biproduct of this global public health epidemic. From clinical to point-of-care applications, the detection and real-time monitoring of this family of drug is critical in the fight to decrease abuse and improve use in clinical settings. Chromatographic separations and chromatography–mass spectrometry are traditional methods of opioid analyses, but the high cost, long analysis time, and absence of portability highlight the need for the development of fast, in situ, point-of-care analysis, or of community drug monitoring services. This review highlights recent electrochemical and optical (FTIR, Raman, colorimetric, and fluorescent) advances and biosensors for pharmaceutical and illicit opioid analysis. Specifically, an emphasis is placed on the detection of opioids and their metabolites in biological samples and in vitro cellular assays for clinical diagnosis and forensic applications. The challenges and prospects of the role of electrochemical sensors, biosensors, and optical sensors for opioid analysis in promoting clinical diagnosis, forensic study, point-of-care, and community drug monitoring services to reduce harm are also provided.