The ability of microglia, the brain's resident macrophage, to present antigen through the class II major histocompatibility complex (MHC) to T cells allows these normally quiescent cells to play a critical role in shaping the outcome of many neurological diseases. The expression of class II MHC antigens and the costimulatory molecules CD40 and B7 on microglia and infiltrating macrophages is regulated through a complex network of cytokines in the inflamed brain. In this review, we describe the molecular mechanisms underlying class II MHC, CD40 and B7 regulation in microglia and macrophages. Our focus is on the cis-elements in the promoters of their genes and the transcription factors activated by cytokines that bind them. The functional implications of aberrant class II MHC, CD40 and B7 expression by microglia and macrophages as related to the diseases of Multiple Sclerosis and Alzheimer's Disease are discussed.