The somatostatin-secreting δ-cells comprise ~5% of the cells of the pancreatic islets. The δ-cells have complex morphology and might interact with many more islet cells than suggested by their low numbers. δ-Cells contain ATP-sensitive potassium channels, which open at low levels of glucose but close when glucose is elevated. This closure initiates membrane depolarization and electrical activity and increased somatostatin secretion. Factors released by neighbouring α-cells or β-cells amplify the glucose-induced effects on somatostatin secretion from δ-cells, which act locally within the islets as paracrine or autocrine inhibitors of insulin, glucagon and somatostatin secretion. The effects of somatostatin are mediated by activation of somatostatin receptors coupled to the inhibitory G protein, which culminates in suppression of the electrical activity and exocytosis in α-cells and β-cells. Somatostatin secretion is perturbed in animal models of diabetes mellitus, which might explain the loss of appropriate hypoglycaemia-induced glucagon secretion, a defect that could be mitigated by somatostatin receptor 2 antagonists. Somatostatin antagonists or agents that suppress somatostatin secretion have been proposed as an adjunct to insulin therapy. In this Review, we summarize the cell physiology of somatostatin secretion, what might go wrong in diabetes mellitus and the therapeutic potential of agents targeting somatostatin secretion or action.