Are quasicrystals stable or metastable? Density functional theory (DFT) is often used to evaluate thermodynamic stability, but quasicrystals are long-range aperiodic and their energies cannot be calculated using conventional ab initio methods. Here, we perform first-principles calculations on quasicrystal nanoparticles of increasing sizes, from which we can directly extrapolate their bulk and surface energies. Using this technique, we determine with high confidence that the icosahedral quasicrystals ScZn7.33 and YbCd5.7 are ground-state phases--revealing that translational symmetry is not a necessary condition for the T = 0 K stability of inorganic solids. Although we find the ScZn7.33 quasicrystal to be thermodynamically stable, we show on a mixed thermodynamic and kinetic phase diagram that its solidification from the melt is nucleation-limited, which illustrates why even stable materials may be kinetically challenging to grow. Our techniques here broadly open the door to first-principles investigations into the structure-bonding-stability relationships of aperiodic materials.