The answer is yes in characteristic $0$.
In fact, take the non-empty Zariski open set $X^0$ where $\pi \colon X \to M$ has finite fibres, and let $M^0 \subset M$ be the image of $X^0$. Then $M^0$ is a Zariski open set of $M$ and the restriction $\pi^0 \colon X^0 \to M^0$ is a finite map. Passing to function fields, this means that $$(\pi^{0})^*(K(M^0)) \subset K(X^0)$$ is a finite field extension, and since we are working in characteristic $0$ it is also separable.
Now we can apply the following result, see [Shafarevich, Basic Algebraic Geometry I, Theorem 4 of Chapter II, page 144]:
Theorem. The set of points where a finite map $f \colon X \to Y$ is unramified is open, and it is nonempty if $f^*(K(Y)) \subset K(X)$ is a separable field extension.
It follows that $\pi^0 \colon X^0 \to M^0$ is generically unramified, so a fortiori $\pi \colon X \to M$ is generically unramified.
If the characteristic of the base field is $p >0$ the result is no longer true, as it is shown by MP's comment about strange curves.