We present the stellar surface mass density {it vs.} gas metallicity ($Sigma_*-Z$) relation for more than 500,000 spatially-resolved star-forming resolution elements (spaxels) from a sample of 653 disk galaxies included in the SDSS IV MaNGA survey. We find a tight relation between these local properties, with higher metallicities as the surface density increases. This relation extends over three orders of magnitude in the surface mass density and a factor of four in metallicity. We show that this local relationship can simultaneously reproduce two well-known properties of disk galaxies: their global mass-metallicity relationship {it and} their radial metallicity gradients. We also find that the $Sigma_* - Z$ relation is largely independent of the galaxys total stellar mass and specific star-formation rate (sSFR), except at low stellar mass and high sSFR. These results suggest that in the present-day universe local properties play a key role in determining the gas-phase metallicity in typical disk galaxies.