5. Given that a line passing through point $P(-5,0)$ intersects the parabola $x^{2}=4 y$ at points $A$ and $B$, and intersects the $y$-axis at point $M$. If $|P A||P B|=2021$, then $|P M|=$ $\qquad$ .
5. $\sqrt{2021}$.

Let the slope of the line passing through point $P(-5,0)$ be $k$. Then its equation is $y=k(x+5)$.
As shown in Figure 2.
$$
\begin{array}{l}
|P B|=\sqrt{k^{2}+1}\left(x_{2}+5\right), \\
|P M|=5 \sqrt{k^{2}+1},
\end{array}
$$

We know
$$
\begin{array}{l}
|P M|^{2}=\left(k^{2}+1\right) \times 25 \\
=\left(k^{2}+1\right)\left(x_{1}+5\right)\left(x_{2}+5\right) \\
=|P A||P B|=2021 \\
\Rightarrow|P M|=\sqrt{2021} .
\end{array}
$$

Substituting into the parabola equation gives
$$
x^{2}-4 k x-20 k=0 \text {. }
$$

Let the x-coordinates of $A$ and $B$ be $x_{1}$ and $x_{2}$, respectively. Then
$$
\begin{array}{l}
\left(x_{1}+5\right)\left(x_{2}+5\right) \\
=x_{1} x_{2}+5\left(x_{1}+x_{2}\right)+25 \\
=-20 k+5 \times 4 k+25=25 .
\end{array}
$$

By $|P A|=\sqrt{k^{2}+1}\left(x_{1}+5\right)$,