Any natural or synthetic drug that has pharmacological
actions similar to those of morphine
It has been apparent for centuries that opium (e.g., heroin) derivatives such as morphine are powerful analgesics. Animal studies in the 1900s showed that a variety of brain regions are susceptible to the action of opiate drugs, particularily the periaqueductal gray matter and the rostral ventral medulla. There are also opiate-sensitive regions at the level of the spinal cord. In other words -- the areas that produce analgesia when stimulated are also responsive to exogenous opiates.
The analgesic action of opiates implied the existence of specific brain receptors for those drugs long before the receptors were actually found (which happened in the sixties and seventies. Since it's unlikely that those receptors evolved to respond to the administration of opium, scientists started to believe that there must be endogenous compounds for which the receptors had evolved. Several categories of endogenous opiods have been isolated from the brain.
Neuroscience, Sinaur Associates (QP355.2.N487 1997)