Momentum is the generator of spacial translations, even in classical physics. Anyway, you can find a derivation here or in Sakurai's book Modern Quantum Mechanics. They are more or less the same and go like this:
The translation operator is the operator $T( a)$ such that
$$T( a) \mid x \rangle = \mid x+a\rangle$$
From the definition it follows that the adjoint of $T$ performs a backwards translation:
$$T^\dagger(a) \mid x \rangle = \mid x-a\rangle$$
Of course, we must require that if we translate and then translate back the state is unchanged:
$$T^\dagger(a) T(a) \mid x \rangle = \mid x \rangle$$
From which it follows that $T$ must be unitary: $T^\dagger=T^{-1}$
Any unitary operator can be written in the form
$$T(a) =e^{-iKa}$$
with $K$ hermitian. Now you will find that the eigenstates of $K$ in the position basis are plane waves:
$$\langle x \mid k \rangle = \psi_k(x) \sim e^{ikx}$$
Now (and this is the crucial passage), the De Broglie hypothesis comes into play:
$$p = \hbar k$$
so that
$$T(a)=e^{-iPa/\hbar}$$
And with some math (the passages are in the paper I linked) you can show that
$$P \psi(x) = \langle x \mid P \mid x \rangle = - i \hbar \frac{\partial \psi}{\partial x}$$
The De Broglie hypotesis is not strictly necessary. For example Sakurai observes that for an infinitesimal translation you have
$$T(dx) = 1-i K dx$$
and that in classical mechanics the generating function of the infinitesimal translation
$$x'=x+dx$$
$$p'=p$$
is
$$F(x,p')=x p'+ p dx$$
where $xp'$ is the generating function of the identity transformation. From the similarity between $F(x,p')$ and $T(dx)$ he then speculates that $K$ is related to momentum, and since $K \ dx$ must be dimensionless we must have
$$K=\frac{P}{\text{constant with dimensions of an action}}$$
It turns out from experiments that our constant is exactly $\hbar$.