The prediction that variability in ambient pH will influence the intensity and retention of learned predator recognition in juvenile rainbow trout Oncorhynchus mykiss was tested under laboratory conditions. Juvenile rainbow trout were conditioned to recognize the odour of a novel predator at pH 6·0 or 7·0 and then tested for learned recognition of the predator odour at pH 6·0 or 7·0 at 2 or 7 days post-conditioning. When tested 2 days post-conditioning, rainbow trout exhibited a significant learned antipredator response regardless of predator odour pH. The response was stronger, however, when the test pH matched the conditioning pH. When tested 7 days post-conditioning, rainbow trout only exhibited a learned response when conditioning and testing pH were the same. These results demonstrate that episodic acidification may impair the strength and retention of acquired predator recognition learning. Given the demonstrated survival benefits associated with learned predator recognition in prey fishes, such impairment will probably have considerable negative impacts at both individual and population levels.