The role of gammadelta T cells in adaptive immunity remains uncertain. Recent studies have demonstrated that a unique subset of gammadelta T cells in primates can mount adaptive immune responses during mycobacterial infections. This Review discusses notable similarities and differences in adaptive immune responses between non-peptide-specific gammadelta T cells and peptide-specific alphabeta T cells, and discusses both the molecular basis for gammadelta T-cell responses and potential functions of these enigmatic cells.