  A hypothetical time-variation of the gravitational constant $G$ would cause
neutron star matter to depart from beta equilibrium, due to the changing
hydrostatic equilibrium. This forces non-equilibrium beta processes to occur,
which release energy that is invested partly in neutrino emission and partly in
heating the stellar interior. Eventually, the star arrives at a stationary
state in which the temperature remains nearly constant, as the forcing through
the change of $G$ is balanced by the ongoing reactions. Comparing the surface
temperature of the nearest millisecond pulsar, PSR J0437-4715, inferred from
ultraviolet observations, with our predicted stationary temperature, we
estimate two upper limits for this variation: (1) $|\dot G/G| < 2 \times
10^{-10}$ yr$^{-1}$, if we allow direct Urca reactions operating in the neutron
star core, and (2) $|\dot G/G| < 4 \times 10^{-12}$ yr$^{-1}$, considering only
modified Urca reactions. Both results are competitive with those obtained by
other methods, with (2) being among the most restrictive.
