Organisms must adapt to changing environments, and behavioural flexibility plays an important role in adaptation within an individual\'s lifetime. Stress resilience influences flexibility, as short-term stress can enhance attention and memory, while prolonged stress may impair cognitive function. Nutritional state also plays a role, with overweight individuals often suffering greater consequences of chronic stress. The allostatic load model predicts that these individuals, under prolonged stress, remain in a chronically activated state, potentially reducing flexibility. Using a social cichlid, we manipulated body condition and exposed individuals to occasional or frequent predator presentations. We then assessed stress responses and behavioural flexibility via a reversal learning test. Contrary to predictions, fish in a high nutritional state exposed to frequent predators recovered rapidly from stress and exhibited enhanced flexibility. Our results provide direct evidence that nutritional state interacts with behavioural flexibility, revealing the costs of coping with repeated stressors. We highlight a link between brief stress responses, characterized by rapid cortisol recovery, and improved flexibility. This association only emerged in well-nourished individuals facing frequent stressors, suggesting energy reserves buffer the costs of repeated stress. Thus, resilience benefits behavioural flexibility, but it is also energetically costly, as a reduced diet hindered adaptation to environmental change.