Before exposure to antigen, antibodies with a wide diversity of antigen-binding sites are created by V(D)J rearrangement. After exposure to antigen, further diversification is accomplished by means of somatic hypermutation of the antibody variable region genes and class-switch recombination between the heavy-chain mu constant region and the downstream gamma, epsilon, and alpha constant region. The variable region mutations are responsible for the affinity maturation of the antibody response, whereas class-switch recombination enables the antibodies to be distributed throughout the body and to carry out different effector functions. Both somatic mutation and class switching require an enzyme called activation-induced cytidine deaminase (AID) that converts deoxycytidines to deoxyuracils on single-stranded DNA. Genetic defects of AID in human subjects result in hyper-IgM syndrome type 2. The analysis of both mutant mice and immunodeficient patients has led to a better understanding of the mechanism of action and role of AID in immunity, as well as in the malignant transformation of B cells.