Measurements are reported of the central exclusive production of \jpsi and \psitwos mesons in pp collisions at a centre-of-mass energy of 13 TeV. Backgrounds are significantly reduced compared to previous measurements made at lower energies through the use of new forward shower counters. The products of the cross-sections and the branching fractions for the decays to dimuons, where both muons are within the pseudorapidity range 2.0<η<4.5, are measured to be $$
\begin{array}{rcl} \sigma_{J/\psi\rightarrow\mu^+\mu^-}&=&435 \pm 18 \pm 17 \pm 16 {\rm \ pb},\\ \sigma_{\psi(2S)\rightarrow\mu^+\mu^-}&=&11.1 \pm 1.1 \pm 0.3 \pm 0.4 {\rm \ pb}.\\ \end{array} $$ The first uncertainties are statistical, the second are systematic, and the third are due to the luminosity determination. The cross-sections are also measured differentially for meson rapidities between 2.0 and 4.5. Good agreement is observed with theoretical predictions. Photoproduction cross-sections are derived and compared to previous experiments, and a deviation from a pure power-law extrapolation of lower energy data is observed.