Mechanisms of resilience against tau pathology in individuals across the Alzheimer's disease spectrum are insufficiently understood. Longitudinal data are necessary to reveal which factors relate to preserved cognition (i.e. cognitive resilience) and brain structure (i.e. brain resilience) despite abundant tau pathology, and to clarify whether these associations are cross-sectional or longitudinal. We used a longitudinal study design to investigate the role of several demographic, biological and brain structural factors in yielding cognitive and brain resilience to tau pathology as measured with PET. In this multicentre study, we included 366 amyloid-β-positive individuals with mild cognitive impairment or Alzheimer's disease dementia with baseline 18F-flortaucipir-PET and longitudinal cognitive assessments. A subset (n = 200) additionally underwent longitudinal structural MRI. We used linear mixed-effects models with global cognition and cortical thickness as dependent variables to investigate determinants of cognitive resilience and brain resilience, respectively. Models assessed whether age, sex, years of education, APOE-ε4 status, intracranial volume (and cortical thickness for cognitive resilience models) modified the association of tau pathology with cognitive decline or cortical thinning. We found that the association between higher baseline tau-PET levels (quantified in a temporal meta-region of interest) and rate of cognitive decline (measured with repeated Mini-Mental State Examination) was adversely modified by older age (Stβinteraction = -0.062, P = 0.032), higher education level (Stβinteraction = -0.072, P = 0.011) and higher intracranial volume (Stβinteraction = -0.07, P = 0.016). Younger age, higher education and greater cortical thickness were associated with better cognitive performance at baseline. Greater cortical thickness was furthermore associated with slower cognitive decline independent of tau burden. Higher education also modified the negative impact of tau-PET on cortical thinning, while older age was associated with higher baseline cortical thickness and slower rate of cortical thinning independent of tau. Our analyses revealed no (cross-sectional or longitudinal) associations for sex and APOE-ε4 status on cognition and cortical thickness. In this longitudinal study of clinically impaired individuals with underlying Alzheimer's disease neuropathological changes, we identified education as the most robust determinant of both cognitive and brain resilience against tau pathology. The observed interaction with tau burden on cognitive decline suggests that education may be protective against cognitive decline and brain atrophy at lower levels of tau pathology, with a potential depletion of resilience resources with advancing pathology. Finally, we did not find major contributions of sex to brain nor cognitive resilience, suggesting that previous links between sex and resilience might be mainly driven by cross-sectional differences.