The production cross-sections of $J/\psi$ mesons in proton-proton collisions at a centre-of-mass energy of $\sqrt{s}=5$ TeV are measured using a data sample corresponding to an integrated luminosity of $9.13\pm0.18~\text{pb}^{-1}$, collected by the LHCb experiment. The cross-sections are measured differentially as a function of transverse momentum, $p_{\text{T}}$, and rapidity, $y$, and separately for $J/\psi$ mesons produced promptly and from beauty hadron decays (nonprompt). With the assumption of unpolarised $J/\psi$ mesons, the production cross-sections integrated over the kinematic range $0<p_{\text{T}}<20~\text{GeV}/c$ and $2.0<y<4.5$ are $8.154\pm0.010\pm0.283~\mu\text{b}$ for prompt $J/\psi$ mesons and $0.820\pm0.003\pm0.034~\mu\text{b}$ for nonprompt $J/\psi$ mesons, where the first uncertainties are statistical and the second systematic. These cross-sections are compared with those at $\sqrt{s}=8$ TeV and $13$ TeV, and are used to update the measurement of the nuclear modification factor in proton-lead collisions for $J/\psi$ mesons at a centre-of-mass energy per nucleon pair of $\sqrt{s_{\text{NN}}}=5$ TeV. The results are compared with theoretical predictions.
We have studied the transverse-momentum ($p_{\rm T}$) dependence of the inclusive J/$\psi$ production in p-Pb collisions at $\sqrt{s_{\rm NN}} = 5.02$ TeV, in three center-of-mass rapidity ($y_{\rm cms}$) regions, down to zero $p_{\rm T}$. Results in the forward and backward rapidity ranges ($2.03 < y_{\rm cms} < 3.53$ and $-4.46 <y_{\rm cms}< -2.96$) are obtained by studying the J/$\psi$ decay to $\mu^+\mu^-$, while the mid-rapidity region ($-1.37 < y_{\rm cms} < 0.43$) is investigated by measuring the ${\rm e}^+{\rm e}^-$ decay channel. The $p_{\rm T}$ dependence of the J/$\psi$ production cross section and nuclear modification factor are presented for each of the rapidity intervals, as well as the J/$\psi$ mean $p_{\rm T}$ values. Forward and mid-rapidity results show a suppression of the J/$\psi$ yield, with respect to pp collisions, which decreases with increasing $p_{\rm T}$. At backward rapidity no significant J/$\psi$ suppression is observed. Theoretical models including a combination of cold nuclear matter effects such as shadowing and partonic energy loss, are in fair agreement with the data, except at forward rapidity and low transverse momentum. The implications of the p-Pb results for the evaluation of cold nuclear matter effects on J/$\psi$ production in Pb-Pb collisions are also discussed.