Loss of β cell identity, the presence of polyhormonal cells, and reprogramming are emerging as important features of β cell dysfunction in patients with type 1 and type 2 diabetes. In this study, we have demonstrated that the transcription factor NKX2.2 is essential for the active maintenance of adult β cell identity as well as function. Deletion of Nkx2.2 in β cells caused rapid onset of a diabetic phenotype in mice that was attributed to loss of insulin and downregulation of many β cell functional genes. Concomitantly, NKX2.2-deficient murine β cells acquired non-β cell endocrine features, resulting in populations of completely reprogrammed cells and bihormonal cells that displayed hybrid endocrine cell morphological characteristics. Molecular analysis in mouse and human islets revealed that NKX2.2 is a conserved master regulatory protein that controls the acquisition and maintenance of a functional, monohormonal β cell identity by directly activating critical β cell genes and actively repressing genes that specify the alternative islet endocrine cell lineages. This study demonstrates the highly volatile nature of the β cell, indicating that acquiring and sustaining β cell identity and function requires not only active maintaining of the expression of genes involved in β cell function, but also continual repression of closely related endocrine gene programs.