12. Let the foci of an ellipse be $F_{1}(-1,0)$ and $F_{2}(1,0)$ with eccentricity $e$. A parabola with vertex at $F_{1}$ and focus at $F_{2}$ intersects the ellipse at a point $P$. If $\frac{\left|P F_{1}\right|}{\left|P F_{2}\right|}=e$, then the value of $e$ is $\qquad$.
12. $\frac{\sqrt{3}}{3}$.

In the parabola, the directrix $x=-3$, $|PF_{2}|$ is the distance from point $P$ to the directrix;

In the ellipse, $\frac{|PF_{1}|}{|PF_{2}|}=e$, $|PF_{2}|$ is also the distance from point $P$ to the left directrix.
Therefore, the directrix of the parabola coincides with the left directrix of the ellipse.
Then $\frac{a^{2}}{c}=3$.
Also, $c=1$, so it is easy to know that $e=\frac{\sqrt{3}}{3}$.