In this study, we investigated the prevalence of mental disorders and the use of psychopharmacologic drugs among individuals with cerebral palsy (CP). We studied how the association between CP and mental illness develops over the life course (between ages 5 and 65 years), and how it varies across disability specific factors (intellectual disability, gross motor function and communicative ability). We used logistic regression models on a longitudinal matched case-control data material on all persons with CP in Sweden linked to several administrative registers including, the national patient registers and the pharmaceutical registers.Our results showed that the probability of being diagnosed with mental disorders and being dispensed psychopharmacologic drug was significantly higher among persons with CP compared to persons without CP across the different outcomes [OR=1.52–4.7]. For some mental and neurodevelopmental disorders including sleep disorders, autism, and ADHD, and for the use of anxiolytics and sedatives, there was a sizeable gap already in childhood. However, the excess burden of mental illness appeared to grow over the life course, indicating that adults with CP may be a particularly disadvantaged group. Diagnosis for mental disorders and dispensation for psychopharmacologic drugs were not consistent with respect to disability specific factors, especially communicative and intellectual function, which indicates the need for systematic approaches in the mental health care of individuals with CP.