Human immunodeficiency virus type 1 (HIV-1) infection of the central nervous system (CNS) can lead to the development of HIV-1-associated dementia (HAD). We examined the virological characteristics of HIV-1 in the cerebrospinal fluid (CSF) of HAD subjects to explore the association between independent viral replication in the CNS and the development of overt dementia. We found that genetically compartmentalized CCR5-tropic (R5) T cell-tropic and macrophage-tropic HIV-1 populations were independently detected in the CSF of subjects diagnosed with HIV-1-associated dementia. Macrophage-tropic HIV-1 populations were genetically diverse, representing established CNS infections, while R5 T cell-tropic HIV-1 populations were clonally amplified and associated with pleocytosis. R5 T cell-tropic viruses required high levels of surface CD4 to enter cells, and their presence was correlated with rapid decay of virus in the CSF with therapy initiation (similar to virus in the blood that is replicating in activated T cells). Macrophage-tropic viruses could enter cells with low levels of CD4, and their presence was correlated with slow decay of virus in the CSF, demonstrating a separate long-lived cell as the source of the virus. These studies demonstrate two distinct virological states inferred from the CSF virus in subjects diagnosed with HAD. Finally, macrophage-tropic viruses were largely restricted to the CNS/CSF compartment and not the blood, and in one case we were able to identify the macrophage-tropic lineage as a minor variant nearly two years before its expansion in the CNS. These results suggest that HIV-1 variants in CSF can provide information about viral replication and evolution in the CNS, events that are likely to play an important role in HIV-associated neurocognitive disorders.