The knowledge of stellar ages directly impacts the characterization of a planetary system as it puts strong constraints on the moment when the system was born. Unfortunately, the determination of precise stellar ages is a very difficult task. Different methods can be used to do so (based on isochrones or chemical element abundances) but they usually provide large uncertainties.During its evolution a star goes through processes leading to loss of angular momentum but also changes in its magnetic activity. Building rotation, magnetic, age relations would be an asset to infer stellar ages model independently. Several attempts to build empirical relations between rotation and age (namely gyrochronology) were made with a focus on cluster stars where the age determination is easier and for young stars on the main sequence.For field stars, we can now take advantage of high-precision photometric observations where we can perform asteroseismic analyses to improve the accuracy of stellar ages. Furthermore, the variability in the light curves allow us to put strong constraints on the stellar rotation and magnetic activity. By combining these precise measurements, we are on the way of understanding and improving relations between magnetic activity, rotation, and age, in particular at different stages of stellar evolution.During this talk, I will review the status on gyrochronology relationships based on observations of young cluster stars. Then I will focus on solar-like stars and describe the inferences on stellar ages, rotation, and magnetism that can be provided by high-quality photometric observations such as the ones of the Kepler mission, in particular through asteroseismic analyses.