When bacteria or other pathogens are present in the body, certain white blood cells categorized as phagocytes consume the microorganisms to protect the body from infection.

The process of consuming the pathogen begins when the phagocyte is attracted to chemicals from the pathogen, and through receptors, binds to it. The phagocyte ingests the microbe, encasing it in a compartment called a vacuole. Lysosomes in the phagocyte merge with the vacuole. Its enzymes then kill and digest the pathogen, and release any indigestible remains from the cell. This cell process, called phagocytosis, protects the body by removing pathogens.