Automated closed-loop insulin delivery, also referred to as the 'artificial pancreas', has been an important but elusive goal of diabetes treatment for many decades. This Review discusses the design of an artificial pancreas, its components and clinical results, as well as the advantages and disadvantages of different types of automated closed-loop systems and potential future advances.