Background and Purpose: Opioid‐based drugs are the gold standard medicines for pain relief. However, tolerance and several side effects (i.e. constipation and dependence) may occur upon chronic opioid administration. Photopharmacology is a promising approach to improve the benefit/risk profiles of these drugs. Thus, opioids can be locally activated with high spatiotemporal resolution, potentially minimizing systemic‐mediated adverse effects. Here, we aimed at developing a morphine photo‐derivative (photocaged morphine), which can be activated upon light irradiation both in vitro and in vivo. Experimental Approach Light‐dependent activity of pc‐morphine was assessed in cell‐based assays (intracellular calcium accumulation and electrophysiology) and in mice (formalin animal model of pain). In addition, tolerance, constipation and dependence were investigated in vivo using experimental paradigms. Key results: In mice, pc‐morphine was able to elicit antinociceptive effects, both using external light‐irradiation (hind paw) and spinal cord implanted fibre‐optics. In addition, remote morphine photoactivation was devoid of common systemic opioid‐related undesired effects, namely, constipation, tolerance to the analgesic effects, rewarding effects and naloxone‐induced withdrawal. Conclusion and Implications: Light‐dependent opioid‐based drugs may allow effective analgesia without the occurrence of tolerance or the associated and severe opioid‐related undesired effects. LINKED ARTICLES: This article is part of a themed issue on Advances in Opioid Pharmacology at the Time of the Opioid Epidemic. To view the other articles in this section visit http://onlinelibrary.wiley.com/doi/10.1111/bph.v180.7/issuetoc [ABSTRACT FROM AUTHOR]