Calcist

Style

Buttons

Spacing

How much to show

Decimal places

Text size

Squeeze theorem

The squeeze theorem finds a limit you can't compute directly by trapping the function between two simpler functions with the same limit. Here's the statement, the method and the classic examples.

By the Calcist team · Updated October 29, 2026 · About a 6-minute read

The statement

If g(x) ≤ f(x) ≤ h(x) for all x near a (except possibly at a),
and lim g(x) = lim h(x) = L as x → a, then lim f(x) = L as x → a.

It's also called the sandwich theorem or the pinching theorem. If f is stuck between two functions that both head to L, it has nowhere else to go. It works the same way for one-sided limits, for x → ∞, and for sequences.

How to use it

  1. Find a known bound on the hard part. The usual ones are −1 ≤ sin(anything) ≤ 1 and −1 ≤ cos(anything) ≤ 1.
  2. Multiply or add to build g ≤ f ≤ h. When you multiply by something, check its sign: multiplying by a negative number flips the inequalities.
  3. Show g and h have the same limit.
  4. Conclude that f has that limit too.

Worked examples

1. lim x² sin(1/x) as x → 0. sin(1/x) swings between −1 and 1 infinitely often near 0, so you can't just substitute. But −1 ≤ sin(1/x) ≤ 1, and x² ≥ 0, so

−x² ≤ x² sin(1/x) ≤ x²

Both −x² and x² go to 0 as x → 0, so lim x² sin(1/x) = 0. The same argument shows lim x cos(1/x) = 0, using −|x| ≤ x cos(1/x) ≤ |x|.

2. lim sin x / x as x → ∞. For x > 0, −1/x ≤ sin x / x ≤ 1/x. Both bounds go to 0, so the limit is 0.

3. lim sin x / x as x → 0 (the famous one). Compare areas in the unit circle for a small angle x > 0: the triangle inside the sector, the sector itself and the larger triangle outside it give sin x / 2 ≤ x / 2 ≤ tan x / 2. Dividing through by sin x / 2 and flipping gives

cos x ≤ sin x / x ≤ 1

As x → 0, cos x → 1, so lim sin x / x = 1. (For x < 0 the same inequality holds because both sides are even functions.) This limit is what makes d/dx sin x = cos x; see the derivative rules table. It also gives lim (1 − cos x)/x = 0.

4. A sequence. For aₙ = (−1)ⁿ/n: −1/n ≤ aₙ ≤ 1/n, and both bounds go to 0, so aₙ → 0.

Why it's useful

The squeeze theorem handles functions that oscillate or are defined piecewise, where direct substitution and algebra don't work. It's used to prove the basic trig limits, and it's often the cleanest way to show a limit is 0: if |f(x)| ≤ h(x) and h(x) → 0, then f(x) → 0.

Common mistakes

  • Bounds with different limits. sin(1/x) is between −1 and 1, but those limits are different, so the squeeze theorem says nothing about lim sin(1/x). In fact that limit doesn't exist.
  • Ignoring signs. Multiplying −1 ≤ sin(1/x) ≤ 1 by x (not x²) only gives −x ≤ x sin(1/x) ≤ x when x > 0. Use |x| to cover both sides.
  • Bounds that don't hold near a. The inequalities have to hold on some interval around a (except at a itself), not just at a few points.

See how the bounds pinch the function on the graphing calculator by plotting x^2 sin(1/x), x^2 and −x^2 together. Related ideas: the fundamental theorem of calculus and the derivative calculator.

Sources

Every worked example on this page was checked independently with SymPy.

Questions people ask

What is the squeeze theorem?

If g(x) ≤ f(x) ≤ h(x) near a, and g and h both approach L as x → a, then f(x) also approaches L.

What is the limit of x² sin(1/x) as x approaches 0?

0. Since −x² ≤ x² sin(1/x) ≤ x² and both bounds go to 0, the function is squeezed to 0.

How do you prove that sin x / x approaches 1?

With the squeeze theorem: an area comparison in the unit circle gives cos x ≤ sin x / x ≤ 1 for small x, and cos x → 1.

Is the squeeze theorem the same as the sandwich theorem?

Yes. It's also called the pinching theorem.

Can you use the squeeze theorem for limits at infinity?

Yes. For example, −1/x ≤ sin x / x ≤ 1/x for x > 0 shows that sin x / x → 0 as x → ∞.