We analyse the stellar populations in the host galaxies of 53 X-ray selected
optically dull active galactic nuclei (AGN) at 0.34<z<1.07 with ultra-deep
(m=26.5) optical medium-band (R~50) photometry from the Survey for High-z
Absorption Red and Dead Sources (SHARDS). The spectral resolution of SHARDS
allows us to consistently measure the strength of the 4000 AA break, Dn(4000),
a reliable age indicator for stellar populations. We confirm that most X-ray
selected moderate-luminosity AGN (L_X<10^44 erg/s) are hosted by massive
galaxies (typically M*>10^10.5 M_sun) and that the observed fraction of
galaxies hosting an AGN increases with the stellar mass. A careful selection of
random control samples of inactive galaxies allows us to remove the stellar
mass and redshift dependencies of the AGN fraction to explore trends with
several stellar age indicators. We find no significant differences in the
distribution of the rest-frame U-V colour for AGN hosts and inactive galaxies,
in agreement with previous results. However, we find significantly shallower
4000 AA breaks in AGN hosts, indicative of younger stellar populations. With
the help of a model-independent determination of the extinction, we obtain
extinction-corrected U-V colours and light-weighted average stellar ages. We
find that AGN hosts have younger stellar populations and higher extinction
compared to inactive galaxies with the same stellar mass and at the same
redshift. We find a highly significant excess of AGN hosts with Dn(4000)~1.4
and light weighted average stellar ages of 300-500 Myr, as well as a deficit of
AGN in intrinsic red galaxies. We interpret failure in recognising these trends
in previous studies as a consequence of the balancing effect in observed
colours of the age-extinction degeneracy.Comment: Accepted for publication in MNRAS, 12 pages, 8 figures, 1 tabl