At LHC energies, the charged-particle multiplicity dependence of particle production is a topic of considerable interest in $pp$ collisions. It has been argued that multiple partonic interactions play an important role in particle production mechanisms, not only affecting the soft processes but also the hard processes. Recently, ALICE has measured $J/psi$ production as a function of charged-particle multiplicity to study the correlation between soft and hard processes. In this contribution, we present the $J/psi$ production versus multiplicity for $pp$ and $p-Pb$ collisions measured by ALICE. We compare the results with different theoretical models.