L'Hopital's rule: Replace an indeterminate quotient with a ratio of derivatives

By Vegard Gjerde Based on Masterful Learning 8 min read
lhopitals-rule calculus limits math learning-strategies

L’Hopital’s rule lets you resolve an indeterminate quotient limit — of the form 0/00/0 or /\infty/\infty — by replacing the original ratio f(x)/g(x)f(x)/g(x) with the ratio of their derivatives f(x)/g(x)f'(x)/g'(x) and re-evaluating the limit. It applies when both ff and gg are differentiable near aa and gg' is not zero near aa. Checking the indeterminate form, differentiability, and the derivative-denominator condition before applying the rule is the core fluency skill trained in the Unisium Study System.

Unisium hero image titled L'Hopital's rule showing the principle equation and a conditions card.
L’Hopital’s rule: limxaf(x)g(x)=limxaf(x)g(x)\lim_{x \to a}\dfrac{f(x)}{g(x)}=\lim_{x \to a}\dfrac{f'(x)}{g'(x)} — valid when the quotient is 0/00/0 or /\infty/\infty, both functions are differentiable near aa, and g0g' \neq 0.

On this page: The Principle | Conditions | Failure Modes | EE Questions | Retrieval Practice | Practice Ground | Solve a Problem | FAQ


The Principle

The move: Replace the limit of an indeterminate quotient f(x)/g(x)f(x)/g(x) with the limit of the ratio of their derivatives f(x)/g(x)f'(x)/g'(x).

The invariant: When the form is indeterminate (0/00/0 or /\infty/\infty), the original limit and the derivative-ratio limit share the same value — provided the derivative-ratio limit exists and g0g' \neq 0 near aa.

Pattern: limxaf(x)g(x)limxaf(x)g(x)\lim_{x \to a}\frac{f(x)}{g(x)} \quad \longrightarrow \quad \lim_{x \to a}\frac{f'(x)}{g'(x)}

Legal ✓Illegal ✗
limx0sinxx\lim_{x \to 0}\frac{\sin x}{x}: form is 0/00/0limx0cosx1=1\lim_{x \to 0}\frac{\cos x}{1} = 1limx0x+1x1\lim_{x \to 0}\frac{x+1}{x-1}: form is 11=1\frac{1}{-1}=-1, not indeterminate → applying L’Hopital gives lim11=1\lim\frac{1}{1}=1 ✗ (wrong answer)

Left: the limit is 0/00/0 — the indeterminate condition holds, so the derivative swap is valid. Right: the quotient evaluates directly to 1-1; applying L’Hopital to a non-indeterminate form yields the wrong value and is an invalid use of the rule.


Conditions of Applicability

Condition: 0/0or/0/0 or \infty/\infty; f and g differentiable near a; g0g^{\prime}\neq 0

Before applying, check: first confirm the original quotient tends to 0/00/0 or /\infty/\infty, then verify that both functions are differentiable near aa, and confirm that gg' does not vanish throughout a punctured neighborhood of aa.

If the condition is violated: the derivative-ratio replacement is not justified; it can give the wrong value, or the transformed quotient may fail to represent the original limit at all.

  • The rule does not apply to determinate quotients such as 3/53/5, 0/10/1, or 1/01/0 — only 0/00/0 and /\infty/\infty trigger it.
  • The rule also fails when the required differentiability is missing — for example, when ff or gg has a corner or discontinuity near aa.
  • If the derivative denominator is zero throughout a whole punctured neighborhood of aa, the derivative-ratio step is blocked — this affects both first applications and iterated ones.
  • For other indeterminate forms (00 \cdot \infty, \infty - \infty, 11^\infty, 000^0, 0\infty^0), rewrite into a 0/00/0 or /\infty/\infty quotient first, then re-check all three condition branches.

Want the complete framework behind this guide? Read Masterful Learning.


Common Failure Modes

Failure mode: apply L’Hopital without verifying the indeterminate form — for example, to limx1x+2x3\lim_{x \to 1}\frac{x+2}{x-3} which evaluates to 3/2-3/2 directly → using the derivative ratio 1/1=11/1 = 1 produces the wrong answer.

Debug: always substitute x=ax = a first; if the result is a determinate number, evaluate directly — the rule is not needed and must not be applied.


Elaborative Encoding

Use these questions to build deep understanding. (See Elaborative Encoding for the full method.)

Within the Principle

  • Why does the rule require the form to be 0/00/0 or /\infty/\infty specifically? What goes wrong if the form is 0/10/1 and you still differentiate numerator and denominator?
  • The rule replaces ff and gg with ff' and gg' separately — this is not the quotient rule for derivatives. Why is it valid to differentiate them independently here?

For the Principle

  • Describe a two-step check you can run before applying L’Hopital to any limit of the form limxaf(x)/g(x)\lim_{x \to a} f(x)/g(x).
  • If applying L’Hopital once still leaves an indeterminate form, what can you do? Are there limits of application?

Between Principles

  • The limit quotient rule splits a quotient limit into two separate limits when the denominator limit is nonzero. How does that condition — nonzero denominator limit — relate to the 0/00/0 condition that triggers L’Hopital?

Generate an Example

  • Construct a quotient limit where L’Hopital appears applicable (the expression looks like a fraction) but the form is not indeterminate. Explain what error results from applying the rule anyway.

Retrieval Practice

Answer from memory, then click to reveal and check. (See Retrieval Practice for the full method.)

State the move in one sentence: _____Replace the limit of an indeterminate quotient f(x)/g(x) with the limit of the ratio of their derivatives f'(x)/g'(x), provided the form is 0/0 or infinity/infinity, both functions are differentiable near a, and g' is not zero.
Write the canonical equation: _____limxaf(x)g(x)=limxaf(x)g(x)\lim_{x \to a}\frac{f(x)}{g(x)}=\lim_{x \to a}\frac{f'(x)}{g'(x)}
State the canonical condition: _____0/0or/;f and g differentiable near a;g00/0 or \infty/\infty;\, \text{f and g differentiable near a};\, g^{\prime}\neq 0

Practice Ground

Use these exercises to build move-selection fluency. (See Self-Explanation for how to use worked examples effectively.)

Procedure Walkthrough

Starting from limx0sin3xx\lim_{x \to 0}\dfrac{\sin 3x}{x}, reach a single numeric value.

StepExpressionOperation
0limx0sin3xx\lim_{x \to 0}\dfrac{\sin 3x}{x}
1Confirm 0/00/0: sin(0)/0=0/0\sin(0)/0 = 0/0 ✓; both differentiable near 00; g(x)=10g'(x)=1 \neq 0Condition check
2limx03cos3x1\lim_{x \to 0}\dfrac{3\cos 3x}{1}L’Hopital — differentiate numerator and denominator separately
33cos(0)=3(1)=33\cos(0) = 3(1) = 3Direct substitution

Drills

Action label (Format B)

What was done between these two steps? Is the move valid? Confirm the form before deciding.

limx0ex1xlimx0ex1\lim_{x \to 0}\frac{e^x - 1}{x} \quad \longrightarrow \quad \lim_{x \to 0}\frac{e^x}{1}

Reveal

L’Hopital’s rule applied. Form check: (e01)/0=0/0(e^0 - 1)/0 = 0/0 ✓. Both ex1e^x - 1 and xx are differentiable near 00. g(x)=10g'(x) = 1 \neq 0 ✓. Condition holds.

Completing the evaluation: e0/1=1e^0/1 = 1.


What was done between these two steps? Is the move valid? Confirm the form before deciding.

limxlnxxlimx1/x1\lim_{x \to \infty}\frac{\ln x}{x} \quad \longrightarrow \quad \lim_{x \to \infty}\frac{1/x}{1}

Reveal

L’Hopital’s rule applied. Form check: lnx\ln x \to \infty and xx \to \infty, so the form is /\infty/\infty ✓. Both functions are differentiable for x>0x > 0. g(x)=10g'(x) = 1 \neq 0 ✓. Condition holds.

Completing the evaluation: limx(1/x)/1=0/1=0\lim_{x \to \infty}(1/x)/1 = 0/1 = 0.


What was done between these two steps? Is the move valid? Confirm the form before deciding.

limx0x2xxlimx02x11\lim_{x \to 0}\frac{x^2 - x}{x} \quad \longrightarrow \quad \lim_{x \to 0}\frac{2x - 1}{1}

Reveal

L’Hopital’s rule applied — but check whether it was needed. Form check: (00)/0=0/0(0 - 0)/0 = 0/0 ✓. Conditions are met, so the move is valid.

However, the numerator factors as x(x1)x(x-1), so the limit simplifies directly to limx0(x1)=1\lim_{x \to 0}(x-1) = -1 without L’Hopital. The derivative-ratio route gives limx0(2x1)/1=1\lim_{x \to 0}(2x-1)/1 = -1 — same answer. The rule was valid but unnecessary here.


Can L’Hopital’s rule be applied? Identify the form and explain your decision.

limx2x21x+3\lim_{x \to 2}\frac{x^2 - 1}{x + 3}

Reveal

No — the condition fails. Substituting x=2x = 2: numerator =41=3= 4 - 1 = 3; denominator =5= 5. The form is 3/53/5 — determinate. L’Hopital requires 0/00/0 or /\infty/\infty. The correct answer is 3/53/5 by direct substitution. Applying L’Hopital here would give 2x/14/1=42x/1 \to 4/1 = 4 — wrong.


Can L’Hopital’s rule be applied? Identify the form and explain your decision.

limx0tanxx2\lim_{x \to 0}\frac{\tan x}{x^2}

Reveal

Yes, but only the first application. Form check: tan(0)/0=0/0\tan(0)/0 = 0/0 ✓. Apply once: limx0sec2x/(2x)\lim_{x \to 0}\sec^2 x/(2x). Now check again: sec2(0)/(0)=1/0\sec^2(0)/(0) = 1/0 — the form is 1/01/0, not 0/00/0 or /\infty/\infty. This means the limit does not exist (the expression blows up). L’Hopital cannot be re-applied; the conclusion is that the original limit does not exist.


Forward step (Format A)

Apply L’Hopital’s rule once. State the form check and condition check explicitly.

limx01cosxx\lim_{x \to 0}\frac{1 - \cos x}{x}

Reveal

Form: (1cos0)/0=0/0(1 - \cos 0)/0 = 0/0 ✓. Both functions differentiable near 00; g(x)=10g'(x) = 1 \neq 0 ✓.

limx0sinx1=sin0=0\lim_{x \to 0}\frac{\sin x}{1} = \sin 0 = 0


Apply L’Hopital’s rule as needed. State the form check and condition check at each application.

limxx2ex\lim_{x \to \infty}\frac{x^2}{e^x}

Reveal

Form: /\infty/\infty ✓. Both differentiable; g(x)=ex0g'(x) = e^x \neq 0 ✓.

First application: limx2xex\lim_{x \to \infty}\dfrac{2x}{e^x}. Still /\infty/\infty — re-check: g(x)=ex0g'(x) = e^x \neq 0 ✓.

Second application: limx2ex=0\lim_{x \to \infty}\dfrac{2}{e^x} = 0. Form is now determinate.


Apply L’Hopital’s rule as needed. At each step, flag whether gg' vanishes at aa and confirm the condition still holds in a punctured neighborhood.

limx0xsinxx3\lim_{x \to 0}\frac{x - \sin x}{x^3}

Reveal

Form: (00)/0=0/0(0 - 0)/0 = 0/0 ✓. Both differentiable; g(x)=3x2g'(x) = 3x^2 — note g(0)=0g'(0) = 0, but g(x)0g'(x) \neq 0 for x0x \neq 0 in a punctured neighborhood ✓.

First application: limx01cosx3x2\lim_{x \to 0}\dfrac{1 - \cos x}{3x^2}. Form 0/00/0 ✓; g(x)=6xg'(x) = 6x, nonzero in a punctured neighborhood of 00 ✓.

Second application: limx0sinx6x\lim_{x \to 0}\dfrac{\sin x}{6x}. Form 0/00/0 ✓; g(x)=60g'(x) = 6 \neq 0 ✓.

Third application: limx0cosx6=16\lim_{x \to 0}\dfrac{\cos x}{6} = \dfrac{1}{6}. Determinate — stop.

Key point: L’Hopital requires g0g' \neq 0 near aa, not at aa. The condition holds at each stage because gg' is only zero at the single point x=0x = 0, not throughout any punctured neighborhood.


Transition identification (Format C)

In the evaluation chain below, identify which step applies L’Hopital’s rule. Verify the condition at that step.

limx0sinxxx3\lim_{x \to 0}\frac{\sin x - x}{x^3}

(1)limx0cosx13x2(2)limx0sinx6x(3)limx0cosx6(4)16\xrightarrow{(1)} \lim_{x \to 0}\frac{\cos x - 1}{3x^2} \xrightarrow{(2)} \lim_{x \to 0}\frac{-\sin x}{6x} \xrightarrow{(3)} \lim_{x \to 0}\frac{-\cos x}{6} \xrightarrow{(4)} -\frac{1}{6}

Reveal

Steps (1), (2), and (3) each apply L’Hopital’s rule.

  • Step (1): form (sin00)/0=0/0(\sin 0 - 0)/0 = 0/0 ✓; g(x)=3x2g'(x) = 3x^2, nonzero near but not at 00 ✓.
  • Step (2): form (cos01)/0=0/0(\cos 0 - 1)/0 = 0/0 ✓; g(x)=6xg'(x) = 6x, nonzero near 00 ✓.
  • Step (3): form (sin0)/0=0/0(-\sin 0)/0 = 0/0 ✓; g(x)=60g'(x) = 6 \neq 0 ✓.

Step (4) evaluates cos(0)/6=1/6-\cos(0)/6 = -1/6 by direct substitution — no rule application.


Solve a Problem

Apply what you’ve learned with Problem Solving.

Problem: Evaluate limx0e2x12xx2\lim_{x \to 0}\dfrac{e^{2x} - 1 - 2x}{x^2} using L’Hopital’s rule. State the condition check at each application and stop when the limit is determinate.

Full solution
StepExpressionMove
0limx0e2x12xx2\lim_{x \to 0}\dfrac{e^{2x} - 1 - 2x}{x^2}
1Form: (110)/0=0/0(1 - 1 - 0)/0 = 0/0 ✓; both differentiable; g(x)=2xg'(x)=2x, nonzero near 00Condition check
2limx02e2x22x\lim_{x \to 0}\dfrac{2e^{2x} - 2}{2x}L’Hopital (first application)
3Form: (22)/0=0/0(2 - 2)/0 = 0/0 ✓; g(x)=20g'(x) = 2 \neq 0Condition check
4limx04e2x2\lim_{x \to 0}\dfrac{4e^{2x}}{2}L’Hopital (second application)
54e02=42=2\dfrac{4e^{0}}{2} = \dfrac{4}{2} = 2Direct substitution — form is now determinate

PrincipleRelationship
Limit quotient ruleApplies when the denominator limit is nonzero — the complementary case to L’Hopital’s 0/00/0 trigger
Continuity at a pointExplains when direct substitution suffices and no indeterminate form arises
Limit product ruleUsed to rewrite 00 \cdot \infty forms as a quotient before applying L’Hopital

FAQ

What is L’Hopital’s rule?

L’Hopital’s rule states that limxaf(x)g(x)=limxaf(x)g(x)\lim_{x \to a}\frac{f(x)}{g(x)} = \lim_{x \to a}\frac{f'(x)}{g'(x)} when the original limit is in the indeterminate form 0/00/0 or /\infty/\infty, both functions are differentiable near aa, and gg' is not zero near aa. It converts an unresolvable quotient into a new limit that is often easier to evaluate.

When is L’Hopital’s rule valid?

Three conditions must all hold: (1) the limit of f(x)/g(x)f(x)/g(x) produces a 0/00/0 or /\infty/\infty indeterminate form, (2) ff and gg are differentiable in a punctured neighborhood of aa, and (3) g(x)0g'(x) \neq 0 near aa. If the limit is determinate — any value other than 0/00/0 or /\infty/\infty — the rule must not be applied.

What goes wrong if I apply L’Hopital to a non-indeterminate form?

You get the wrong answer. For example, limx0(x+1)/(x+2)=1/2\lim_{x \to 0}(x+1)/(x+2) = 1/2 by substitution. If you differentiate to get 1/1=11/1 = 1, the result is incorrect. The rule is only valid when the original form is indeterminate.

Can I apply L’Hopital’s rule more than once?

Yes — if the derivative ratio is still indeterminate after one application, check the conditions again and apply the rule a second time. Repeat until the form becomes determinate or it becomes clear the limit does not exist.

Does L’Hopital’s rule apply to forms like 00 \cdot \infty or 11^\infty?

Not directly. Those forms must first be rewritten algebraically as a 0/00/0 or /\infty/\infty quotient — usually by taking a logarithm or rearranging as a fraction — and then L’Hopital can be applied to the resulting quotient.


How This Fits in Unisium

In Unisium, limit fluency is built around checking the indeterminate form, differentiability, and the derivative-denominator condition before applying L’Hopital’s rule. The drills above train the distinguish-and-apply skill: recognizing 0/00/0 or /\infty/\infty forms, rejecting non-indeterminate quotients, and knowing when to apply the rule a second time. Through spaced retrieval practice and action-labeling exercises, that three-part condition check becomes automatic.

Explore further:

  • Calculus Subdomain Map — Return to the calculus map to see where L’Hopital’s rule sits relative to the main limit rules and derivative tools
  • Limit quotient rule — The complementary rule for determinate quotient limits
  • Elaborative Encoding — Build deep understanding of why the indeterminate form is the key guard
  • Retrieval Practice — Make the condition and equation pattern instantly accessible

Ready to master L’Hopital’s rule? Start practicing with Unisium or explore the full learning framework in Masterful Learning.

Masterful Learning book cover

Masterful Learning

The study system for physics, math, & programming that works: retrieval, connection, explanation, problem solving, and more.

Read the book (opens in new tab) ISBN 979-8-2652-9642-9

Ready to apply this strategy?

Join Unisium and start implementing these evidence-based learning techniques.

Start Learning with Unisium Read More Guides

Want the complete framework? This guide is from Masterful Learning.

Learn about the book →