  We investigated the mass-to-light versus color relations (MLCRs) derived from
the spatially resolved star formation history of a sample of 452 galaxies
observed with integral field spectroscopy in the CALIFA survey. We derived the
stellar mass ($M_\star$) and the stellar mass surface density from the
combination of full spectral fitting (using different sets of stellar
population models) with observed and synthetic colors in optical broad bands.
This method allows obtaining the radial structure of the mass-to-light ratio
($M/L$) at several wavelengths and studying the spatially resolved MLCRs. Our
sample covers a wide range of Hubble types from Sc to E, with stellar masses
ranging from $M_\star \sim 10^{8.4}$ to $10^{12}$ M$_\odot$. The scatter in the
MLCRs was studied as a function of morphology, stellar extinction, and emission
line contribution to the colors. The effects of the initial mass function (IMF)
and stellar population models in the MLCRs were also explored. Our main results
are that (a) the $M/L$ ratio has a negative radial gradient that is steeper
within the central 1 half-light-radius (HLR). It is steeper in Sb-Sbc than in
early-type galaxies. (b) The MLCRs between $M/L$ and optical colors were
derived with a scatter of $\sim$ 0.1 dex. Extinction and emission line
contributions do not affect the scatter of these relations. Morphology does not
produce a significant effect, except if the general relation is used for
galaxies redder than $(u-i) > 4$ or bluer than $(u-i) < 0$. (c) The IMF has a
large effect on MLCRs, as expected. The change from a Chabrier to a Salpeter
IMF produces a median shift of $\sim$ \oimf\ dex when mass loss from stellar
evolution is also taken into account. (d) These MLCRs are in agreement with
previous results, in particular for relations with $g$ and $r$ bands and the
$B$ and $V$ Johnson systems. FITS tables available at http://pycasso.iaa.es/ML
