[proofplan]
We extend $f$ and $g$ to $[a, b)$ by defining $f(a) = g(a) = 0$, making both functions continuous at $a$. For each $x \in (a,b)$, [Cauchy's Mean Value Theorem](/theorems/187) applied on $[a, x]$ expresses $f(x)/g(x)$ as $f'(c_x)/g'(c_x)$ for some $c_x \in (a, x)$. Since $c_x \to a^+$ as $x \to a^+$, the hypothesis $\lim_{x \to a^+} f'(x)/g'(x) = L$ gives the result.
[/proofplan]
[step:Extend $f$ and $g$ continuously to the endpoint $a$]
Define $f(a) = 0$ and $g(a) = 0$. Since $\lim_{x \to a^+} f(x) = 0 = f(a)$ and $\lim_{x \to a^+} g(x) = 0 = g(a)$, both $f$ and $g$ are [continuous](/page/Continuity) at $a$ from the right. For each $x \in (a, b)$, the functions $f$ and $g$ are continuous on $[a, x]$ and [differentiable](/page/Derivative) on $(a, x)$.
[/step]
[step:Apply Cauchy's Mean Value Theorem on $[a, x]$ to express $f(x)/g(x)$]
We verify the hypotheses of [Cauchy's Mean Value Theorem](/theorems/187) on $[a, x]$ for each $x \in (a, b)$:
- $f$ and $g$ are continuous on $[a, x]$ (by the extension above and differentiability on $(a, b)$).
- $f$ and $g$ are differentiable on $(a, x)$.
- $g'(t) \neq 0$ for all $t \in (a, x) \subset (a, b)$ by hypothesis.
Cauchy's [Mean Value Theorem](/theorems/186) yields a point $c_x \in (a, x)$ such that
\begin{align*}
\frac{f(x) - f(a)}{g(x) - g(a)} = \frac{f'(c_x)}{g'(c_x)}.
\end{align*}
Since $f(a) = g(a) = 0$:
\begin{align*}
\frac{f(x)}{g(x)} = \frac{f'(c_x)}{g'(c_x)}.
\end{align*}
Note that $g(x) \neq 0$ for $x$ sufficiently close to $a$ (with $x > a$): if $g(x) = 0$ for some $x \in (a, b)$, then $g(a) = 0 = g(x)$, and [Rolle's Theorem](/theorems/185) would give a point $\xi \in (a, x)$ with $g'(\xi) = 0$, contradicting the hypothesis $g' \neq 0$ on $(a, b)$.
[guided]
Before applying [Cauchy's Mean Value Theorem](/theorems/187), we must verify that the quotient $f(x)/g(x)$ is well-defined, i.e., that $g(x) \neq 0$ for all $x \in (a,b)$.
Suppose for contradiction that $g(x_0) = 0$ for some $x_0 \in (a, b)$. Since $g(a) = 0$ (by the extension) and $g$ is [continuous](/page/Continuity) on $[a, x_0]$ and [differentiable](/page/Derivative) on $(a, x_0)$, [Rolle's Theorem](/theorems/185) produces $\xi \in (a, x_0) \subset (a, b)$ with $g'(\xi) = 0$. This contradicts the hypothesis that $g'(t) \neq 0$ for all $t \in (a, b)$. Therefore $g(x) \neq 0$ for all $x \in (a, b)$.
With $g(x) \neq 0$ established, the Cauchy MVT hypotheses are satisfied on $[a, x]$: both $f$ and $g$ are continuous on $[a, x]$ and differentiable on $(a, x)$, and $g'(t) \neq 0$ on $(a, x)$. The theorem yields $c_x \in (a, x)$ with
\begin{align*}
\frac{f(x) - f(a)}{g(x) - g(a)} = \frac{f'(c_x)}{g'(c_x)}.
\end{align*}
Since $f(a) = g(a) = 0$, this simplifies to $f(x)/g(x) = f'(c_x)/g'(c_x)$. The denominator $g(x) - g(a) = g(x) \neq 0$ ensures the left-hand side is well-defined.
[/guided]
[/step]
[step:Take the limit as $x \to a^+$ using $a < c_x < x$]
Since $a < c_x < x$ for each $x$, the squeeze principle gives $c_x \to a^+$ as $x \to a^+$. Therefore
\begin{align*}
\lim_{x \to a^+} \frac{f(x)}{g(x)} = \lim_{x \to a^+} \frac{f'(c_x)}{g'(c_x)} = \lim_{c \to a^+} \frac{f'(c)}{g'(c)} = L,
\end{align*}
where the last equality uses the hypothesis $\lim_{x \to a^+} \frac{f'(x)}{g'(x)} = L$.
[guided]
The crucial observation is that $c_x \in (a, x)$ implies $c_x \to a^+$ as $x \to a^+$. More precisely, for any $\eta > 0$, choosing $x < a + \eta$ ensures $a < c_x < x < a + \eta$, so $c_x$ is eventually within $\eta$ of $a$. This is the squeeze principle: the inequality $a < c_x < x$ pins $c_x$ between $a$ and $x$, forcing $c_x \to a^+$.
Since $\lim_{c \to a^+} f'(c)/g'(c) = L$ by hypothesis, and $c_x \to a^+$, the composition [limit](/page/Limit) gives
\begin{align*}
\lim_{x \to a^+} \frac{f'(c_x)}{g'(c_x)} = \lim_{c \to a^+} \frac{f'(c)}{g'(c)} = L.
\end{align*}
Combined with the exact identity $f(x)/g(x) = f'(c_x)/g'(c_x)$ from [Cauchy's Mean Value Theorem](/theorems/187), we conclude $\lim_{x \to a^+} f(x)/g(x) = L$.
Note that this argument works whether $L$ is finite or infinite ($L = +\infty$ or $L = -\infty$), since the Cauchy MVT identity is exact, not approximate -- we are not passing to a limit inside an approximation, but rather substituting an exact equality.
[/guided]
[/step]