It is an accumulation of immune cells, pus and other material in the brain, usually from a bacterial or fungal infection. Causes Brain abscesses commonly occur when bacteria or fungi infect part of the brain. As a result, swelling and irritation (inflammation) occurs. Infected brain cells, white blood cells, like bacteria or fungi living and dead accumulate in an area of the brain tissue that forms around this area and creates a mass or abscess. Microorganisms which cause a brain abscess usually reach the brain through the blood. Or, directly into the brain, as it can be during brain surgery. Often you not found the source of infection. However, the most common source is a lung infection. Very rarely, the cause is an infection of the heart. The following factors increase the risk of a brain abscess: A weakened immune system (such as AIDS patients). A chronic disease such as cancer.