Differential diagnosis of dementia, with its overlapping symptomatology, remains a significant challenge in neurology. Here we present an algorithmic framework employing state-of-the-art techniques such as transformers as well as self-supervised frameworks and harnessing a broad array of data including demographics, person-level and family medical history, medication use, neuropsychological exams, functional evaluations, and multimodal neuroimaging to identify the etiologies contributing to dementia in individuals. The study utilized 9 independent, geographically diverse datasets, including the National Alzheimer’s Coordinating Center with 45, 349 participants, the Alzheimer’s Disease Neuroimaging Initiative encompassing 1, 821 participants, and the Frontotemporal Lobar Degeneration Neuroimaging Initiative comprising 253 participants. Additionally, the Parkinson’s Progression Marker Initiative with 198 participants, the Australian Imaging, Biomarker and Lifestyle Flagship Study of Ageing cohort including 661 participants, the Open Access Series of Imaging Studies dataset with 491 participants, and the 4 Repeat Tauopathy Neuroimaging Initiative comprising 80 participants were used. The study also included two in-house datasets: one from the Lewy Body Dementia Center for Excellence at Stanford University with 182 participants, and another from the Framingham Heart Study including 1, 651 individuals. Our model traverses the intricate spectrum of dementia by mirroring real-world clinical settings, aligning diagnoses with similar management strategies, and delivering robust predictions, even in the face of incomplete data. On the testing cohort, our model achieved a micro-averaged area under the receiver operating characteristic curve (AUROC) of 0.93, and a micro-averaged area under precision-recall curve (AUPR) of 0.87, in classifying individuals with normal cognition, mild cognitive impairment and dementia. Also, the micro-averaged AUROC was 0.95 and micro-averaged AUPR was 0.68 in differentiating 10 distinct dementia etiologies, defined through a consensus among a team of neurologists. One key strength lies in our model’s capability to address mixed dementias, a prevalent challenge in clinical practice, and the incorporation of interpretability techniques further unveiled vital disease-specific patterns. On a randomly selected subset (n= 100), our model differentiated true positive and true negative cases across 12 out of 13 categories (p< 0.01), as opposed to the neurologists’ expertise in identifying 9 out of these 13 categories (p< 0.01). Furthermore, the model’s correlations with different proteinopathies were substantiated through postmortem analyses. This included a significant association with the global Alzheimer’s disease neuropathologic change (ADNC) score (p< 0.001), and notable correlations with TDP-pathology, the presence of old microinfarcts, arteriosclerosis, and Prion disease (all withp< 0.05). Our framework has the potential to be integrated as a screening tool for dementia in various clinical settings and drug trials, with promising implications for person-level management.Research in contextSystematic review:Previous studies have demonstrated that models utilizing multimodal data can differentiate individuals across the dementia spectrum, identifying those with normal cognition (NC), mild cognitive impairment (MCI), and dementia (DE). Some studies have also ventured beyond this tripartite classification, aiming to differentiate Alzheimer’s disease (AD) from other forms of non-AD dementia. Majority of these investigations have approached the task as a binary classification, primarily focusing on the distinction between AD and other dementia types. Also, limited studies have effectively tackled the intricate challenge of diagnosing mixed dementia, which is a common and complex issue encountered in clinical practice.Methods and findings:Employing multimodal data from 9 distinct cohorts, encompassing 50, 686 participants, we developed an algorithmic framework that leverages transformers and self-supervised learning to facilitate differential dementia diagnoses. This model adeptly classifies individuals into 13 curated diagnostic categories, each tailored to reflect real-world clinical needs. These categories comprehensively cover the cognitive spectrum, ranging from NC, MCI to DE, and extend to 10 distinct dementia types. Our model demonstrates the capability to accurately diagnose dementia, even with incomplete data, and efficiently manage cases involving multiple co-occurring dementia conditions, a common occurrence in clinical practice. It has shown commendable performance, surpassing expert clinical assessments, and its predictions have been corroborated by postmortem data, particularly in relation to various proteinopathies.Interpretation:Our work provides a robust and adaptable framework for comprehensive dementia screening for drug trials and in various clinical settings, ranging from primary care to memory clinics.