  We analyze the feasibility to estimate the stellar mass of galaxies by
mid-infrared luminosities based on a large sample of galaxies cross-identified
from $Spitzer$ SWIRE fields and SDSS spectrographic survey. We derived the
formulae to calculate the stellar mass by using IRAC 3.6$\mu$m and 4.5$\mu$m
luminosities. The mass-to-luminosity ratios of IRAC 3.6$\mu$m and 4.5$\mu$m
luminosities are more sensitive to star formation history of galaxies than
other factors, such as the intrinsic extinction, metallicity and star formation
rate. To remove the affection from star formation history, we used g-r color to
recalibrate the formulae and obtain a better result. It must be more careful to
estimate the stellar mass of low metallicity galaxies using our formulae. Due
to the emission from dust heated by hottest young stars, luminous infrared
galaxies present higher IRAC 4.5 $\mu$m luminosity compared to IRAC 3.6 $\mu$m
luminosity. For most of type-II AGNs, the nuclear activity can not enhance
3.6$\mu$m and 4.5$\mu$m luminosities compared with normal galaxies. The star
formation in our AGN-hosting galaxies is also very weak, almost all of which
are early-type galaxies.
