An agent for improving brain function and agent for preventing or treating cognitive impairment, which comprises: 5 to 50 parts by weight of a protein; 5 to 80 parts by weight of a medium-chain fatty acid triglyceride as a lipid; and 1 to 50 parts by weight of a carbohydrate, per 100 parts by weight.