  We compute the two-loop electroweak correction to the production of the Higgs
boson in gluon fusion to higher orders in the dimensional-regularization
parameter $\epsilon = (d-4)/2$. We employ the method of differential equations
to compute the relevant integrals and express them in terms of Goncharov
polylogarithms. Our result provides one of the necessary inputs for the
computation of mixed three-loop QCD-electroweak corrections to $gg \to H$.
