Any of a class of histocompatibility proteins encoded by the major histocompatibility complex whose expression is restricted to certain immune cells, in particular B cells, macrophages, other antigen-presenting cells, epithelial cells of the thymus, and (in humans) activated T cells. These proteins bind antigenic peptide fragments derived from pathogens or toxins that have been taken in and degraded by macrophages or B cells and held in vesicles within the cell. The class II proteins then migrate to the cell surface, where they are recognized by receptors of CD4-bearing T cells (i.e. helper T cells), which in turn activate the presenting cell to kill its intracellular pathogens (in the case of macrophages) or to secrete antibodies to neutralize extracellular bacteria or circulating toxins (in the case of B cells). Class II proteins consist of an α chain and a β chain and have a peptide-binding site that is open at both ends and can accommodate longer peptides than MHC class I molecules.