[proofplan]
By [Embedding Criterion](/theorems/2195), the canonical morphism $\phi_{K_C}$ is an embedding if and only if $K_C$ satisfies condition $(*)$. We prove the two directions of the equivalence "embedding $\iff$ not hyperelliptic" by reformulating each as a statement about condition $(*)$:
(⇒) If $\phi_{K_C}$ fails to be an embedding, then condition $(*)$ fails at some $\{p, q\}$, meaning $\ell(K_C - p - q) \geq g - 1$. Riemann–Roch applied to $D := p + q$ then forces $\ell(p + q) \geq 2$, producing a degree-$2$ rational function on $C$, hence a degree-$2$ morphism $C \to \mathbb{P}^1_k$, hence $C$ is hyperelliptic.
(⇐) If $C$ is hyperelliptic, choose a degree-$2$ morphism $\pi: C \to \mathbb{P}^1_k$. For a generic fibre $\{p, q\} = \pi^{-1}(t_0)$, the divisor $D := p + q$ has $\ell(D) \geq 2$ (the constants $1$ and the pullback function $\pi^*\!\!\left(\tfrac{1}{t - t_0}\right)$). Riemann–Roch gives $\ell(K_C - p - q) \geq g - 1$, violating condition $(*)$ at $\{p, q\}$. By [Embedding Criterion](/theorems/2195), $\phi_{K_C}$ is not an embedding.
The translation between condition $(*)$ on $K_C$ and the existence of a degree-$2$ morphism $C \to \mathbb{P}^1_k$ uses Riemann–Roch and the fact that $\ell(K_C) = g$.
[/proofplan]
[step:Recall the dimension of the canonical Riemann–Roch space]
For a smooth projective curve $C$ of genus $g \geq 2$, the canonical divisor $K_C$ satisfies $\deg K_C = 2g - 2$ by [Degree of the Canonical Divisor](/theorems/2186), and Riemann–Roch applied to $D = K_C$ gives
\begin{align*}
\ell(K_C) - \ell(K_C - K_C) &= \deg K_C - g + 1, \\
\ell(K_C) - \ell(0) &= (2g - 2) - g + 1 = g - 1, \\
\ell(K_C) &= g - 1 + \ell(0) = g - 1 + 1 = g.
\end{align*}
Hence $\mathcal{L}(K_C)$ is a $g$-dimensional $k$-vector space, and a basis $\{f_1, \ldots, f_g\}$ defines the canonical morphism
\begin{align*}
\phi_{K_C}: C &\to \mathbb{P}^{g - 1}_k, \\
p &\longmapsto [f_1(p) : \cdots : f_g(p)],
\end{align*}
which is a morphism by [Rational Maps from Smooth Curves Are Morphisms](/theorems/2172) (since $C$ is smooth, every rational map to projective space extends to a morphism).
[/step]
[step:Translate "$\phi_{K_C}$ is not an embedding" via the Embedding Criterion]
By [Embedding Criterion](/theorems/2195), $\phi_{K_C}$ is a closed embedding if and only if $K_C$ satisfies condition $(*)$ — that is, for every pair $p, q \in C$ (not necessarily distinct),
\begin{align*}
\ell(K_C - p - q) = \ell(K_C) - 2 = g - 2.
\end{align*}
Therefore $\phi_{K_C}$ fails to be an embedding if and only if there exist $p, q \in C$ with $\ell(K_C - p - q) \geq g - 1$.
[/step]
[step:Forward direction: failure of $(*)$ produces a degree-$2$ morphism to $\mathbb{P}^1_k$]
Suppose $\phi_{K_C}$ is not an embedding. By Step 2, there exist closed points $p, q \in C$ (possibly equal) with
\begin{align*}
\ell(K_C - p - q) \geq g - 1. \tag{$\dagger$}
\end{align*}
Set $D := p + q$, an effective divisor of degree $2$. Apply Riemann–Roch to $D$:
\begin{align*}
\ell(D) - \ell(K_C - D) = \deg D - g + 1 = 2 - g + 1 = 3 - g.
\end{align*}
Substituting the bound $(\dagger)$ — note that $K_C - D = K_C - p - q$, so $\ell(K_C - D) \geq g - 1$:
\begin{align*}
\ell(D) = (3 - g) + \ell(K_C - D) \geq (3 - g) + (g - 1) = 2.
\end{align*}
So $\ell(p + q) \geq 2$. Since $\mathcal{L}(p + q)$ contains the constant function $1$ (because $\operatorname{div}(1) + (p + q) = p + q \geq 0$), and has dimension at least $2$, there exists a *non-constant* function $f \in \mathcal{L}(p + q)$ — that is, $f$ is a rational function on $C$ with $\operatorname{div}(f) + p + q \geq 0$, so $f$ has poles only at $p$ and $q$, each of order at most $1$ (or, if $p = q$, a double pole at $p$).
The function $f$ defines a rational map
\begin{align*}
f: C &\dashrightarrow \mathbb{P}^1_k, \\
x &\longmapsto [1 : f(x)],
\end{align*}
which is a morphism by [Rational Maps from Smooth Curves Are Morphisms](/theorems/2172). It is non-constant because $f$ is not constant. The degree of this morphism equals the degree of the polar divisor $(f)_\infty$, which is at most $\deg(p + q) = 2$. Since the morphism is non-constant, its degree is at least $1$, so the degree is in $\{1, 2\}$.
If the degree were $1$, the morphism $f: C \to \mathbb{P}^1_k$ would be an isomorphism between smooth projective curves (degree-$1$ morphisms of smooth projective curves are isomorphisms by the equivalence of categories with finitely generated function fields of transcendence degree $1$), forcing $g(C) = g(\mathbb{P}^1_k) = 0$, contradicting the hypothesis $g \geq 2$. Hence the degree is exactly $2$, and $C$ is hyperelliptic.
[/step]
[step:Reverse direction: hyperelliptic $C$ forces failure of $(*)$ on $K_C$]
Suppose $C$ is hyperelliptic. By definition, there exists a non-constant morphism $\pi: C \to \mathbb{P}^1_k$ of degree $2$.
For each closed point $t \in \mathbb{P}^1_k$, the scheme-theoretic fibre $\pi^{-1}(t)$ is a divisor on $C$ of degree equal to $\deg \pi = 2$. There are at most finitely many ramification points (where the fibre is a single doubled point); for $t$ outside this finite ramification locus, the fibre consists of two distinct points, $\pi^{-1}(t) = \{p, q\}$ with $p \neq q$, and the corresponding divisor is $D := p + q$ on $C$.
Pick such a regular fibre $\{p, q\}$ — concretely, choose any $t_0 \in \mathbb{P}^1_k$ which is not a branch point of $\pi$ and is not the image of $\infty \in \mathbb{P}^1_k$ (such $t_0$ exists since the branch locus is finite and $\mathbb{P}^1_k$ is infinite for $k$ algebraically closed). The divisor $D := p + q = \pi^{-1}(t_0)$ has degree $2$.
[claim:For the regular fibre $D = \pi^{-1}(t_0)$, $\ell(D) \geq 2$]
We exhibit two linearly independent functions in $\mathcal{L}(D)$. The constant function $1 \in \mathcal{L}(D)$ since $\operatorname{div}(1) + D = D \geq 0$. The rational function
\begin{align*}
g := \pi^*\!\!\left(\frac{1}{t - t_0}\right) \in K(C)
\end{align*}
— the pullback of the rational function on $\mathbb{P}^1_k$ with simple pole at $t_0$ and simple zero at $\infty$ — has divisor $\operatorname{div}(g) = \pi^*(\operatorname{div}(\tfrac{1}{t - t_0})) = \pi^*([\infty] - [t_0])$. By the fibre-pullback formula for nonconstant morphisms of smooth projective curves, $\pi^*([\infty]) = \pi^{-1}(\infty)$ (counted with ramification multiplicity) and $\pi^*([t_0]) = \pi^{-1}(t_0) = D$ (since $t_0$ is unramified). Hence
\begin{align*}
\operatorname{div}(g) = \pi^{-1}(\infty) - D,
\end{align*}
so $\operatorname{div}(g) + D = \pi^{-1}(\infty) \geq 0$, giving $g \in \mathcal{L}(D)$. The function $g$ is non-constant (it has nontrivial divisor: zeros over $\infty$, poles over $t_0$), so $\{1, g\}$ is linearly independent in $\mathcal{L}(D)$, and $\ell(D) \geq 2$.
[/claim]
[proof]
We exhibit the two linearly independent functions $1, g$ explicitly above, and verify both lie in $\mathcal{L}(D)$ via the divisor calculations. Linear independence follows because $g$ is non-constant.
[/proof]
Now apply Riemann–Roch to $D$:
\begin{align*}
\ell(D) - \ell(K_C - D) = \deg D - g + 1 = 2 - g + 1 = 3 - g.
\end{align*}
Rearranging:
\begin{align*}
\ell(K_C - D) = \ell(D) - (3 - g) = \ell(D) + g - 3.
\end{align*}
Using the claim $\ell(D) \geq 2$:
\begin{align*}
\ell(K_C - p - q) = \ell(K_C - D) \geq 2 + g - 3 = g - 1.
\end{align*}
This violates condition $(*)$ at the pair $\{p, q\}$, since condition $(*)$ requires $\ell(K_C - p - q) = g - 2$, strictly less than $g - 1$.
By [Embedding Criterion](/theorems/2195), $\phi_{K_C}$ is therefore not an embedding.
[guided]
The proof is the bidirectional translation between two phenomena: the existence of a degree-$2$ morphism $C \to \mathbb{P}^1_k$ (hyperellipticity) and the failure of condition $(*)$ on the canonical divisor $K_C$ (canonical map not an embedding). Riemann–Roch is the dictionary; the [Embedding Criterion](/theorems/2195) makes condition $(*)$ the correct intermediate notion.
**Why look at $K_C - p - q$ at all?** The question "is $\phi_{K_C}$ an embedding?" reduces to "does $K_C$ satisfy condition $(*)$?" by [Embedding Criterion](/theorems/2195). Condition $(*)$ asks $\ell(K_C - p - q) = \ell(K_C) - 2 = g - 2$. So the failure of $(*)$ is the inequality $\ell(K_C - p - q) \geq g - 1$.
**The Riemann–Roch dictionary.** Riemann–Roch applied to $D = p + q$ gives
\begin{align*}
\ell(p + q) - \ell(K_C - p - q) = \deg(p+q) - g + 1 = 3 - g.
\end{align*}
Rearrange: $\ell(p + q) = \ell(K_C - p - q) - g + 3$. So $\ell(K_C - p - q) \geq g - 1$ is equivalent to $\ell(p + q) \geq 2$. The failure of condition $(*)$ on $K_C$ at the pair $\{p, q\}$ is exactly the existence of a non-constant function in $\mathcal{L}(p + q)$.
**A non-constant function in $\mathcal{L}(p + q)$ is a degree-$2$ map.** If $f \in \mathcal{L}(p + q)$ is non-constant, $f$ has poles only at $p, q$ (each at most simple). The map $x \mapsto [1 : f(x)]$ is then a morphism $C \to \mathbb{P}^1_k$ whose degree is the degree of the polar part of $f$, at most $2$. The degree cannot be $1$ (that would force $C \cong \mathbb{P}^1_k$, contradicting $g \geq 2$), so it is exactly $2$. Hence $C$ is hyperelliptic.
**The reverse direction.** If $C$ is hyperelliptic with a degree-$2$ map $\pi: C \to \mathbb{P}^1_k$, every regular fibre $\pi^{-1}(t_0)$ is a divisor $D = p + q$ of degree $2$ for which $1$ and the pullback $\pi^*\!\!\left(\tfrac{1}{t - t_0}\right)$ both lie in $\mathcal{L}(D)$ — giving $\ell(D) \geq 2$. Reversing the dictionary, $\ell(K_C - p - q) = \ell(D) + g - 3 \geq g - 1$, so condition $(*)$ fails on $K_C$ at this $\{p, q\}$.
**Geometric content of the failure.** Geometrically, the canonical map $\phi_{K_C}$ identifies $p$ with $q$ for any regular fibre of the hyperelliptic involution: the canonical map factors through the hyperelliptic involution, and the image $\phi_{K_C}(C)$ is a rational normal curve in $\mathbb{P}^{g - 1}_k$, on which $\phi_{K_C}$ is a $2$-to-$1$ cover. So the canonical map is not injective on the closed points of $C$.
**Why $g \geq 2$ matters.** The hypothesis $g \geq 2$ is used in two places:
(i) For the canonical map to land in $\mathbb{P}^{g - 1}_k$ with $g - 1 \geq 1$, we need $g \geq 2$. For $g = 0$ the canonical map does not exist ($\ell(K_C) = 0$), and for $g = 1$ the canonical map collapses to a point ($\ell(K_C) = 1$).
(ii) The forward direction rules out degree-$1$ morphisms by using $g \geq 2$ to contradict $C \cong \mathbb{P}^1_k$. Without this, the dichotomy "embedding or hyperelliptic" would have to include a third case "rational" — but rational smooth projective curves are exactly $\mathbb{P}^1_k$ itself, of genus $0$.
**The rich consequence.** The Canonical Embedding Theorem is the precise sense in which the canonical bundle is "ample iff the curve is non-hyperelliptic". For non-hyperelliptic $C$ of genus $g \geq 3$, the canonical map embeds $C$ into $\mathbb{P}^{g - 1}_k$, giving a *canonical model* of $C$ with no choices required (up to $\mathrm{PGL}_g$). For hyperelliptic $C$ of genus $g \geq 2$, the canonical map is a $2$-to-$1$ cover of a rational normal curve, and one must use higher pluricanonical bundles (such as $3K_C$, the [Triple Canonical Embedding](/theorems/2198)) to obtain an embedding.
**Genus-$2$ case.** For $g = 2$, every smooth projective curve is hyperelliptic ([All Genus-2 Curves Are Hyperelliptic](/theorems/2194)), so the canonical map is *never* an embedding for $g = 2$ — it is always the degree-$2$ hyperelliptic cover $C \to \mathbb{P}^1_k$. The canonical embedding theorem is interesting starting from $g = 3$, where the dichotomy "hyperelliptic vs not" becomes nontrivial: there exist non-hyperelliptic curves of every genus $g \geq 3$, and for those the canonical map gives a smooth embedding $C \hookrightarrow \mathbb{P}^{g - 1}_k$.
[/guided]
[/step]