I'm trying to prove the following
If $f: \mathbb{R} \rightarrow \mathbb{R}$ is a ring homomorphism, $f \equiv id_{\mathbb{R}}$.
My argument is as follows, since $f(1) = 1$, for $n\in\mathbb{N}$ we have
$$ f(n) = f(1 + \dots + 1) = f(1) +\dots+ f(1) = nf(1) = n $$
and therefore $f(k) = k$ for any integer $k$ (if negative, it suffices to note that $f(-k) = -f(k) = -k$).
This implies that $f$ is the identity when restricted to $\mathbb{Q}$ because if $\frac{p}{q}$ is rational with $p,q \in \mathbb{Z}$,
$$ f(\frac{p}{q}) = f(pq^{-1}) = f(p)f(q^{-1}) = f(p)f(q)^{-1} = pq^{-1} = \frac{p}{q} $$
On the other hand, $f$ is order preserving: if $x \geq 0$, it has a positive square root $y$, and then
$$ f(x) = f(y^2) = f(y)^2 \geq 0 $$
To conclude the claim, then, it suffices to show that $f(w) = w$ for $w$ irrational. If $w \in \mathbb{R} \setminus \mathbb{Q}$, it is clear that if $Q_w = \{q \in \mathbb{Q} : q< w\}$, $w = \sup Q_w$. We will then prove that $f(w)$ is the supremum of this set, and by unicity, we will have $f(w) = w$. To see that $f(w)$ is an upper bound, one must simply observe that if $q < w$ is a rational number, $q = f(q) < f(w)$. Finally, if $L$ is another upper bound, since $w < L$ we have a rational $L' \in (w,L)$ and therefore $f(w) < f(L') = L' < L$.
Does this argument sound correct? If so, can any simplifications be made to the last part? Proving the subcase for $\mathbb{Q}$ is fairly direct, but the extension to the whole real line feels a bit clumsy.
I find the last part extremely well written, actually.
If anything, let's put it in another way : for any $w \in R \setminus Q$, and for any $q_1<w<q_2$ rationals, we have $$f(q_1)<f(w)<f(q_2)$$ by order preserving nature of $f$, leading to $q_1<f(w)<q_2$. Since this is true for all rationals $q_1$ and $q_2$ such that $w$ is between them, the conclusion is that $w=f(w)$, otherwise you could pick a rational $w < q_3 < f(w)$ (or the other way) to get a contradiction.