Dear Yusky, consider a proper holomorphic map of complex spaces $f:X\to Y$. (Please note that there is absolutely no condition on these complex spaces)
You can consider the set of connected components of the fibres of $f$: call that set $|Y'|$.
Stein factorization tells you that you can endow that set with the structure of a complex space $Y'=(|Y'|,\mathcal O_Y)$ so that there is a canonical factorization $f=\pi\circ f'$, where $\pi:Y'\to Y$ is a finite morphism and $f':Y \to Y'$ is holomorphic, proper, surjective with connected fibers and satisfies $f'_{\ast}\mathcal O_X=\mathcal O_Y'$.
The universal property you are looking for is the following :
Universal property If $g: X\to Z$ is a morphism of complex spaces constant on the connected components of the fibers of $f$, then there is is a unique holomorphic map $g':Y'\to Z$ with $g=g'\circ f'$.
This is due to Stein, Remmert and Cartan, and uses some powerful tool: either Remmert's proper mapping theorem, according to which the proper image of an analytic set is analytic or Grauert's celebrated (even stronger) direct image theorem, according to which the direct image of a coherent sheaf under a proper holomorphic map is coherent.
Bibliography What could be a better reference than a book written by the two giants of twentieth century complex analysis mentioned above? Look at page 219 of
Grauert, H. and Remmert, R.: Coherent analytic sheaves. Grundl. Math. Wiss. 265, Springer- Verlag (1984).