Digital technologies are beginning to transform the practice of medicine, and the field of surgery is no different. This npj Digital Medicine special collection highlights work being done in several areas of digital technology, such as machine learning, computer vision, wearable devices, remote patient monitoring, and virtual and augmented reality, which are all poised to transform surgery in the coming years. AI enabled decision support systems have the potential to predict surgical outcomes, which is important for patient care both preoperatively and postoperatively. Challenges to the adoption of these technologies include the need for more data to train machine learning models, the need for more robust and accurate algorithms, and the need for better integration of digital technologies into existing clinical workflows.