6. Let the circumcenter of the tetrahedron $S-ABC$ be $O$, the midpoints of $SB$ and $AC$ be $N$ and $M$ respectively, and the midpoint of segment $MN$ be $P$. Given that $SA^2 + SB^2 + SC^2 = AB^2 + BC^2 + AC^2$, if $SP = 3\sqrt{7}$ and $OP = \sqrt{21}$, then the radius of the sphere $O$ is $\qquad$
6. $2 \sqrt{21}$.

Let $\overrightarrow{S A}=x, \overrightarrow{S B}=y, \overrightarrow{S C}=z, \overrightarrow{B C}=a, \overrightarrow{C A}=\boldsymbol{b}$,
$$
\overrightarrow{A B}=c \text {. }
$$

Then $a=z-y, b=x-z, c=y-x$.
Also, $S A^{2}+S B^{2}+S C^{2}=A B^{2}+B C^{2}+C A^{2}=m$
$\Rightarrow|\boldsymbol{a}|^{2}+|\boldsymbol{b}|^{2}+|\boldsymbol{c}|^{2}$
$=2\left(|x|^{2}+|y|^{2}+|z|^{2}\right)-$
$2(y \cdot z+z \cdot x+x \cdot y)$
$\Rightarrow 2(y \cdot z+z \cdot x+x \cdot y)=m$.
It is easy to get $\overrightarrow{S P}=\frac{1}{4}(x+y+z)$.
Let $\overrightarrow{S O}=\boldsymbol{r}$. Then $\overrightarrow{O A}=\boldsymbol{x}-\boldsymbol{r}$.
$$
\begin{array}{l}
\text { By }|\overrightarrow{S O}|=|\overrightarrow{O A}| \\
\Rightarrow|r|^{2}=|r|^{2}-2 r \cdot x+|x|^{2} \\
\Rightarrow|x|^{2}=2 r \cdot x .
\end{array}
$$

Similarly, $|y|^{2}=2 r \cdot y,|z|^{2}=2 r \cdot z$.
Thus, $|x|^{2}+|y|^{2}+|z|^{2}$
$$
=2 \boldsymbol{r} \cdot(\boldsymbol{x}+\boldsymbol{y}+\boldsymbol{z})=8 \boldsymbol{r} \cdot \overrightarrow{S P} \text {. }
$$

Also, $|\overrightarrow{S P}|^{2}=(3 \sqrt{7})^{2}$
$$
=\frac{1}{16}(x+y+z)^{2}=\frac{1}{8} m \text {, }
$$

Then
$$
\begin{array}{l}
m=8 \times 63 \Rightarrow \boldsymbol{r} \cdot \overrightarrow{S P}=63 . \\
\text { By } \overrightarrow{O P}=\overrightarrow{O S}+\overrightarrow{S P} \\
\Rightarrow 21=|\boldsymbol{r}|^{2}-2 \boldsymbol{r} \cdot \overrightarrow{S P}+63=|\boldsymbol{r}|^{2}-63 \\
\Rightarrow|r|=2 \sqrt{21} .
\end{array}
$$