6. Given the sequence $\left\{a_{n}\right\}$ satisfies $a_{1}=1, a_{n+1}=a_{n}+\frac{1}{2 a_{n}}$, then $\lim _{n \rightarrow \infty}\left(a_{n}-\sqrt{n}\right)=$
6. 0 .

From $a_{n+1}=a_{n}+\frac{1}{2 a_{n}}$, we get
$$
a_{n+1}^{2}=a_{n}^{2}+\frac{1}{4 a_{n}^{2}}+1 .
$$

By mathematical induction, we can prove $n \leqslant a_{n}^{2}<n+\sqrt[3]{n}$, thus
$$
0 \leqslant a_{n}-\sqrt{n}<\sqrt{n+\sqrt[3]{n}}-\sqrt{n}=\frac{\sqrt[3]{n}}{\sqrt{n+\sqrt[3]{n}}+\sqrt{n}}<\frac{\sqrt[3]{n}}{\sqrt{n}}=\frac{1}{\sqrt[6]{n}},
$$

and since $\lim _{n \rightarrow \infty} \frac{1}{\sqrt[6]{n}}=0$, it follows that $\lim _{n \rightarrow \infty}\left(a_{n}-\sqrt{n}\right)=0$.