Why is the statement $(\forall x\in\mathbb R)(x^2\ge0)$ true even when $x$ is not a real number? It seems obvious that the statement $(\forall x\in\mathbb R)(x^2\ge0)$ is true. To prove it, however, we need to show that the implication $x\in\mathbb R\to x^2\ge0$ holds for all $x$. But suppose that $x$ is not a real number. Then, $x^2$ is not defined, and so presumably $x^2\ge0$ does not have a truth value (and nor does $x\in\mathbb R\to x^2\ge0$). Therefore, it is unclear to me how the implication $x\in\mathbb R\to x^2\ge0$ can be true for all $x$. What am I missing?

There are two ways to remedy this issue (namely the well-formedness of the statement):
Locally: Restrict the language (or domain of discourse) so that this statement is only well formed with respect to real numbers, that is quantification is over real numbers. In this case there is no need to include the hypothesis $(x\in \mathbb R)$ to a quantifier. This would result in the statement

"In the theory of real numbers, $\forall x. x^2 \geq 0$."

Globally: If we choose to keep your domain of discourse to be say, set theory, then we must generalize all real function and relation symbols so that they are total. For example, multiplication and ordering on real numbers produces a value for any set. Since we add the hypothesis that $x\in \mathbb R$ whenever quantifying over $x$, it does not matter how we define these operations on sets. This results in the statement

"In the theory of sets, $\forall x. (x\in \mathbb R)\implies (x^2\geq 0)$, and whenever $x\not\in \mathbb R$ or $y\not\in\mathbb R$, we define $x * y := 0$ and $x \geq y$ to be true."

There is also a third option if you view your statement in type theory, in which multiplication and ordering is defined only for real numbers, but quantification is now indexed by a type. This guarantees that the following is well formed

"$\forall_{\mathbb R} x. x^2 \geq 0$."

