5. The maximum value of the function $y=x\left(1+\sqrt{1-x^{2}}\right)$ is

保留了源文本的换行和格式。
5. $\frac{3 \sqrt{3}}{4}$.

From the problem, we know $|x| \leqslant 1$.
Since we are looking for the maximum value, we can assume $0 < x \leqslant 1$.
Let $x=\sin \alpha\left(\alpha \in\left(0, \frac{\pi}{2}\right]\right)$. Then
$$
\begin{aligned}
y= & \sin \alpha(1+\cos \alpha) \\
\Rightarrow & y^{\prime}=\cos \alpha(1+\cos \alpha)+\sin \alpha(-\sin \alpha) \\
& =\cos \alpha+\cos 2 \alpha .
\end{aligned}
$$

Let $y^{\prime}=0$, i.e.,
$$
\begin{array}{l}
\cos \alpha+\cos 2 \alpha=0 \\
\Rightarrow 2 \alpha=\pi-\alpha \Rightarrow \alpha=\frac{\pi}{3} \\
\Rightarrow x=\frac{\sqrt{3}}{2}, y=\frac{3 \sqrt{3}}{4} .
\end{array}
$$