Disordered immune responses are supposed to alter the function of the central nervous system through the neuroendocrine immunomodulation network. In this paper, we studied the influence of the immune function on learning performances from the angle of pharmacology using aged garlic extract (AGE), an immunomodulator. Splenocyte proliferation, induced by concanavalin A or lipopolysaccharide, and the antibody production response were declined in senescence accelerated mouse-prone 8 (SAMP8) aged 12 months compared with age-matched SAMR1 (SAM-resistant 1). Chronic oral administration of AGE-containing food (2%, w/w) significantly enhanced the immune responses of both SAMP8 and SAMR1. Male ddY mice were thymectomized 4 weeks after birth and fed AGE-containing food after the operation until the experiments were finished. Learning performances, brain monoamine content and choline acetyltransferase (ChAT) activity, as well as the immune response were evaluated 10 months after the operation. Thymectomy resulted in not only immunodeficiency, but also deteriorated learning ability. AGE treatment prevented the reduction of the antibody production response induced by thymectomy and improved the thymectomy-induced deterioration of learning behaviours in passive avoidance performance and in a spatial memory task. The contents of hypothalamic noradrenaline, 3,4-dihydroxyphenylacetic acid and homovanillic acid, and the hypothalamic ChAT activity were increased in thymectomized mice compared to those of sham-operated control, while AGE treatment restored them to the control levels. These results suggest that the improvement of immune function is closely related to the amelioration of age-associated deterioration of learning and memory.