Measuring the clustering of galaxies from surveys allows us to estimate the power spectrum of matter density fluctuations, thus constraining cosmological models. This requires careful modelling of observational effects to avoid misinterpretation of data. In particular, signals coming from different distances encode information from different epochs. This is known as light-cone effect and is going to have a higher impact as upcoming galaxy surveys probe larger redshift ranges. Generalising the method by Feldman et al. (1994), I define a minimum-variance estimator of the linear power spectrum at a fixed time, properly taking into account the light-cone effect. An analytic expression for the estimator is provided, and that is consistent with the findings of previous works in the literature. I test the method within the context of the halo model, assuming Planck 2014 cosmological parameters. I show that the estimator presented recovers the fiducial linear power spectrum at present time within 5% accuracy up to $k sim 0.80;h,mathrm{Mpc}^{-1}$ and within 10% up to $k sim 0.94;h,mathrm{Mpc}^{-1}$, well into the non-linear regime of the growth of density perturbations. As such, the method could be useful in the analysis of the data from future large-scale surveys, like Euclid.