  We analyze the color gradients (CGs) of ~50000 nearby SDSS galaxies. From
synthetic spectral models based on a simplified star formation recipe, we
derive the mean spectral properties, and explain the observed radial trends of
the color as gradients of the stellar population age and metallicity (Z). The
most massive ETGs (M_* > 10^{11} Msun) have shallow CGs in correspondence of
shallow (negative) Z gradients. In the stellar mass range 10^(10.3-10.5) < M_*
< 10^(11) Msun, the Z gradients reach their minimum of ~ -0.5 dex^{-1}. At M_*
~ 10^{10.3-10.5} Msun, color and Z gradient slopes suddenly change. They turn
out to anti-correlate with the mass, becoming highly positive at the very low
masses. We have also found that age gradients anti-correlate with Z gradients,
as predicted by hierarchical cosmological simulations for ETGs. On the other
side, LTGs have gradients which systematically decrease with mass (and are
always more negative than in ETGs), consistently with the expectation from gas
infall and SN feedback scenarios. Z is found to be the main driver of the trend
of color gradients, especially for LTGs, but age gradients are not negligible
and seem to play a significant role too. We have been able to highlight that
older galaxies have systematically shallower age and Z gradients than younger
ones. Our results for high-mass galaxies are in perfect agreement with
predictions based on the merging scenario, while the evolution of LTGs and
younger and less massive ETGs seems to be mainly driven by infall and SN
feedback. (Abridged)
