A measurement of the time-dependent CP-violating asymmetry in {B}_s^0to phi phi decays is presented. Using a sample of proton-proton collision data corresponding to an integrated luminosity of 5.0 fb−1 collected by the LHCb experiment at centre-of-mass energies sqrt{s} = 7 TeV in 2011, 8 TeV in 2012 and 13 TeV in 2015 and 2016, a signal yield of around 9000 {B}_s^0to phi phi decays is obtained. The CP-violating phase {phi}_s^{soverline{s}s} is measured to be −0.073 ± 0.115(stat) ± 0.027(syst) rad, under the assumption it is independent of the helicity of the ϕϕ decay. In addition, the CP-violating phases of the transverse polarisations under the assumption of CP conservation of the longitudinal phase are measured. The helicity-independent direct CP-violation parameter is also measured, and is found to be |λ| = 0.99 ± 0.05(stat) ± 0.01(syst). In addition, T-odd triple-product asymmetries are measured. The results obtained are consistent with the hypothesis of CP conservation in overline{b}to overline{s}soverline{s}s transitions. Finally, a limit on the branching fraction of the B0 → ϕϕ decay is determined to be mathcal{B}left({B}^0to phi phi right)<2.7times {10}^{-8} at 90 % confidence level.