Why 1728 in $j$-invariant?

The $j$-invariant for elliptic curves has a $1728$ in it. According to Hartshorne, this is supposedly for characteristic-$2$ and $3$ reasons, despite appearances to the contrary.

Indeed, it is unfathomable why it would help in char $2$ and $3$ when it would vanish.

For that matter, the functions $g_2$, $g_3$ and $\Delta$ too have these constants. Is there a “good reason” why these exist, other than historical reasons? And why are they kept on when we pass to abstract algebraic geometry, when $1728$ only seems to do harm?

Solutions Collecting From Web of "Why 1728 in $j$-invariant?"

Indeed, it is unfathomable why it would help in char 2 and 3 when it would vanish.

It doesn’t vanish, in characteristic 2 or 3! Instead, it cancels out the coefficients that would make it otherwise impossible to define the $j$-invariant.

Also, note that the $j$-invariant doesn’t have a 1728 in it: the 1728 only appears in the specific formula for the $j$-invariant of a curve expressed in short Weierstrass form.

In characteristic $2$ and $3$, you can’t write elliptic curves in short Weierstrass form!

An instructive exercise (it helped me) is to take the forms that you need to use for characteristic $2$ (or $3$), and use the same form to express a rational elliptic curve. Then, compute it’s $j$-invariant (e.g. by converting the curve to short Weierstrass form). You’ll see the $2$’s or $3$’s cancel out.

@user8268’s comment provides the essence, just let me add some detail. The $1728$ removes a common factor from the $q$-power series coefficients of the normalized modular discriminant (with $q=\mathrm{e}^{2\pi\mathrm{i}\tau}$ and $\tau$ the period ratio), as in:
$$\eta^{24}(\tau) = \Delta^*(\tau) = \frac{\operatorname{E}_4^3(\tau)-\operatorname{E}_6^2(\tau)}{1728} = \frac{g_2^3(1,\tau)-27\,g_3^2(1,\tau)}{(2\pi)^{12}}$$
where $\eta$ is the Dedekind eta function and $\operatorname{E}_4$ and $\operatorname{E}_6$ are the Eisenstein series normalized to a limit of $1$ for $\Im\tau\to\infty$, that is, $g_2(1,\tau) = \frac{4}{3}\pi^4\operatorname{E}_4(\tau)$ and $g_3(1,\tau)=\frac{8}{27}\pi^6\operatorname{E}_6(\tau)$.

In particular, the first nonzero $q$-power series coefficient of the normalized modular discriminant is $1$, and all following coefficients are integers. Given that the $q$-power series coefficients of $\operatorname{E}_4$ happen to be integers too, a consequence of the normalization is that the $q$-power series coefficients of
$$j = \frac{\operatorname{E}_4^3}{\Delta^*} = \frac{1728\operatorname{E}_4^3}{\operatorname{E}_4^3-\operatorname{E}_6^2} = \frac{1728 g_2^3}{g_2^3-27g_3^2}$$
are integers as well.