A microscopic model for the resistance drift in the phase-change memory is proposed based on the first-principles results on the compressed amorphous Ge 2Sb 2Te 5. First, it is shown that the residual pressure in the phase-change memory cell can be significant due to the density change accompanying the phase transformation. Our previous first-principles calculations showed that the energy gap is reduced and the density of localized in-gap states increases as the cell is pressurized. This indicates that the compressed amorphous Ge 2Sb 2Te 5 is more conducting than those made under stress-free conditions. In addition, the crystallization dynamics was also accelerated under compressive stress. Based on these theoretical results, we propose a mechanism for the resistance drift in which the relaxation process in the amorphous Ge 2Sb 2Te 5 corresponds to the growth of the crystalline nuclei inside the amorphous matrix, thereby lowering the internal stress. Our model can consistently explain several experimental observations such as the dependence of the drift exponent on the amorphous size.