Is the group of integer points of a simple real linear algebraic group a maximal closed subgroup? Let $ G $ be a simple linear algebraic group. Let $ G_\mathbb{R} $ be the real points of $ G $. Let $ G_\mathbb{Z} $ be the integer points of $ G $. Is $ G_\mathbb{Z} $ a maximal closed subgroup? In other words, are the only closed subgroups $ H $ of $ G_\mathbb{R} $ such that
$$
G_\mathbb{Z} \subset H \subset G_\mathbb{R}
$$
just $ G_\mathbb{R} $ and $ G_{\mathbb{Z}} $?
The answer is yes for for $\operatorname{SO}_3$. $ \operatorname{SO}_3(\mathbb{Z}) $ is the 24 element octohedral group (isomorphic to the symmetric group $ S_4 $) and this group is a maximal finite subgroup of rotations and indeed it turns out that adding any other rotation and taking the closure will generate all of $ \operatorname{SO}_3(\mathbb{R})$.
The group of integer points is also maximal in $ \operatorname{SL}_n(\mathbb R) $. See the answer by YCor given to Is $\operatorname{SL}_2(\mathbb Z)$ a maximal discrete subgroup in $\operatorname{SL}_2(\mathbb R)$?.
Although this only states that $ \operatorname{SL}_n(\mathbb{Z}) $ is maximal among discrete subgroups I'm guessing that it is in fact maximal among closed subgroups as well in this case.
 A: Your guess is correct: if $H$ is a closed subgroup containing $\operatorname{SL}_n({\mathbb Z})$,then it is a Lie subgroup. If $\mathfrak h$ is its Lie algebra, then $\mathfrak h$ is stable under the adjoint action of $SL_n(\mathbb Z)$ and hence under  all of $\operatorname{SL}_n(\mathbb R)$ (since $\operatorname{SL}_n(\mathbb Z)$ is Zariski dense in $\operatorname{SL}_n(\mathbb R)$). If $\mathfrak h$ is non-zero, that means, by the simplicity of $\operatorname{SL}_n(\mathbb R)$, that  $\mathfrak h$ is the Lie algebra of $\operatorname{SL}_n(\mathbb R)$ and hence $H$ is  all of $\operatorname{SL}_n(\mathbb R)$.
If $\mathfrak h =0$, then $H$ is discrete and you have accepted the result in this case.
In the generality that you have asked, $G(\mathbb Z)$ need not be maximal in $G(\mathbb R)$; if $G$ is a simply connected semi-simple algebraic group over $\mathbb Q$ (and is $\mathbb Q$-simple), with $G(\mathbb R)$ non-compact,  and $K_p$ is a maximal compact open subgroup of $G(\mathbb Q_p)$ for each prime $p$, then the intersection of $G(\mathbb Q)$ with all the $K_p$ may be "called" $G(\mathbb Z)$ and the same argument goes through to say that  $G(\mathbb Z)$ is maximal among closed subgroups of $G(\mathbb R)$.
A: Regarding cases where $G(\mathbb{Z})$ is not maximal in $G(\mathbb{R})$: If I am just allowed to take $G$ to be any simple group scheme over $\mathbb{Z}$, then I take
$$\left\{ (X,Y) : X \left[ \begin{smallmatrix} 2&0 \\ 0&1 \\ \end{smallmatrix} \right] = \left[ \begin{smallmatrix} 2&0 \\ 0&1 \\ \end{smallmatrix} \right] Y,\ \det X = \det Y = 1 \right\} \subset (SL_2)^2.$$
In other words, this is the functor which, to any commutative ring $R$, assigns the set of solutions to these equations in pairs of $2 \times 2$ matrices over $R$.
Over $\mathbb{Z}[1/2]$, this is just isomorphic to $SL_2$, since we can parameterize it as
$$(X,\ \left[\begin{smallmatrix} 2&0 \\ 0&1 \\ \end{smallmatrix}\right] X \left[\begin{smallmatrix} 1/2&0 \\ 0&1 \\ \end{smallmatrix}\right] ).$$
However, the pair
$$(\left[\begin{smallmatrix} a&b \\ c&d \end{smallmatrix}\right],\ 
\left[\begin{smallmatrix} a&2b \\ c/2&d \end{smallmatrix}\right])$$
is a $\mathbb{Z}$-valued point if and only if $c \equiv 0 \bmod 2$, so $G(\mathbb{Z})$ is the subgroup $\Gamma_0(2)$ of $SL_2(\mathbb{Z})$.
I do not know an example which does not seem artificial like this.
