  We investigate how the properties of dark energy affect the cosmological
measurements of neutrino mass and extra relativistic degrees of freedom. We
limit ourselves to the most basic extensions of $\Lambda$ cold dark matter
(CDM) model, i.e. the $w$CDM model with one additional parameter $w$, and the
$w_{0}w_{a}$CDM model with two additional parameters, $w_{0}$ and $w_{a}$. In
the cosmological fits, we employ the 2015 cosmic microwave background
temperature and polarization data from the Planck mission, in combination with
low-redshift measurements such as the baryon acoustic oscillations, Type Ia
supernovae and the Hubble constant ($H_{0}$). Given effects of massive
neutrinos on large-scale structure, we further include weak lensing, redshift
space distortion, Sunyaev--Zeldovich cluster counts and Planck lensing data. We
show that, though the cosmological constant $\Lambda$ is still consistent with
the current data, a phantom dark energy ($w<-1$) or an early phantom dark
energy (i.e. quintom evolving from $w<-1$ to $w>-1$) is slightly more favoured
by current observations, which leads to the fact that in both $w$CDM and
$w_0w_a$CDM models we obtain a larger upper limit of $\sum m_\nu$. We also show
that in the three dark energy models, the constraints on $N_{\rm eff}$ are in
good accordance with each other, all in favour of the standard value 3.046,
which indicates that the dark energy parameters almost have no impact on
constraining $N_{\rm eff}$. Therefore, we conclude that the dark energy
parameters can exert a significant influence on the cosmological weighing of
neutrinos, but almost cannot affect the constraint on dark radiation.
