EEG primarily measures the electrical activity of the cortex, the outermost layer of the brain. This layer is composed of six distinct layers, each containing different types of neurons and glial cells. Histological examination of cortical tissues helps us understand the structural basis of the electrical signals captured by EEG.