  Measurements of differential cross-sections for $J/\psi$ production in p+Pb
collisions at $\sqrt{s_{NN}}$ = 5.02 TeV at the LHC with the ATLAS detector are
presented. The data set used corresponds to an integrated luminosity of 28.1
nb$^{-1}$. The $J/\psi$ mesons are reconstructed in the dimuon decay channel
over the transverse momentum range $8<p_{\mathrm{T}}<30$ GeV and over the
center-of-mass rapidity range $-2.87<y^{*}<1.94$. Prompt $J/\psi$ are separated
from $J/\psi$ resulting from $b$-hadron decays through an analysis of the
distance between the $J/\psi$ decay vertex and the event primary vertex. The
differential cross-section for production of nonprompt $J/\psi$ is compared to
a FONLL calculation that does not include nuclear effects. Forward-backward
production ratios are presented and compared to theoretical predictions. These
results constrain the kinematic dependence of nuclear modifications of
charmonium and $b$-quark production in p+Pb collisions.
