Five experiments studied retrograde impairments in Pavlovian fear conditioning following prolonged exposure to the opioid receptor agonist morphine. Injections of morphine commencing 1-7 days but not 14 days after conditioning produced amnesia for that conditioning episode. This amnesia was (a) selective such that morphine impaired freezing to the conditioning context but not to the auditory conditioned stimulus, (b) independent of the interval between the last injection of morphine and test, and (c) accompanied by a failure of contextual discrimination. Context preexposure protected context conditioning and discrimination from the amnestic effects of morphine. These results show that retrograde deficits in contextual fear conditioning are mediated by failures to consolidate a contextual representation.