Adapted from University of Texas libguide
A digital object identifier (DOI) is a unique string of letters and/or numbers that is assigned to online resources like journal articles, data sets, and technical reports. A DOI is persistent, meaning it will not change even if the location of the item changes over time. DOIs make it easy to reliable cite online resources and are recommended as part of a complete citation in several citation style guidelines.
Here's a couple examples of what a DOI looks like:
DOIs are standardized by the International Organization for Standardization (ISO), but they are not just a series of letters and numbers that identify a digital object. DOIs contain descriptive information (metadata) that helps to describe and identify that particular object. Required descriptive information includes:
When a DOI is created, it creates a record with a registration agency that can be updated if the digital object moves to a different URL. That allows the DOI to stay the same while updating information about it like the URL.
DOIs are assigned through registration agencies like DataCite or Crossref. Many publishers have agreements with those registration agencies to create DOIs for the works they publish.