practicecalculus
Trigonometric derivatives

Derivative of cot x: Formula, Proof and Examples

The derivative of cot x is -csc²x. See the quotient rule proof, the -(1 + cot²x) form, the chain rule for cot(u) and examples like cot(2x).

Trigonometric derivatives Updated 2 min read

At a glance

\frac{d}{dx}\,\cot x = -\csc^2 x
Derivative
-\csc^2 x for x \ne k\pi
Other forms
-\dfrac{1}{\sin^2 x} = -(1 + \cot^2 x)
Chain rule form
\dfrac{d}{dx}\cot u = -\csc^2 u \cdot u'
Slope at x = π/2
-\csc^2\frac{\pi}{2} = -1
Integral version
\int \csc^2 x\,dx = -\cot x + C
On this page
  1. Graph of cot x and its derivative
  2. Proof with the quotient rule
  3. A second proof from tan x
  4. The chain rule version: derivative of cot(u)
  5. Worked examples
  6. How to remember it
  7. Common mistakes

The derivative of \cot x is -\csc^2 x. It is the "co" partner of \frac{d}{dx}\tan x = \sec^2 x: swap to the co-functions and add a minus sign.

\frac{d}{dx}\,\cot x = -\csc^2 x

Graph of cot x and its derivative

Graph of y = cot x and its derivative y = -csc²x
One branch of \cot x on (0, \pi). It always falls, and the slope is least steep at x = \frac{\pi}{2}, where it equals -1.

Proof with the quotient rule

Write \cot x = \frac{\cos x}{\sin x} and use the quotient rule:

\frac{d}{dx}\cot x = \frac{(-\sin x)\sin x - \cos x\cos x}{\sin^2 x} = \frac{-(\sin^2 x + \cos^2 x)}{\sin^2 x}

The top is -1, so

\frac{d}{dx}\cot x = -\frac{1}{\sin^2 x} = -\csc^2 x

A second proof from tan x

Since \cot x = (\tan x)^{-1}, the chain rule and the derivative of tan x give

-(\tan x)^{-2}\sec^2 x = -\frac{\cos^2 x}{\sin^2 x}\cdot\frac{1}{\cos^2 x} = -\frac{1}{\sin^2 x}

Same result. The identity \csc^2 x = 1 + \cot^2 x also lets you write the answer as -(1 + \cot^2 x).

The chain rule version: derivative of cot(u)

\frac{d}{dx}\,\cot u = -\csc^2 u\cdot u'
Function Inside u Derivative
\cot(2x) 2x -2\csc^2(2x)
\cot(x^3) x^3 -3x^2\csc^2(x^3)
\cot\sqrt{x} \sqrt{x} -\frac{\csc^2\sqrt{x}}{2\sqrt{x}}
\cot(\pi - x) \pi - x \csc^2(\pi - x)

Worked examples

Example 1: a power. \frac{d}{dx}\cot^2 x = 2\cot x\cdot(-\csc^2 x) = -2\cot x\csc^2 x.

Example 2: a product. \frac{d}{dx}(x\cot x) = \cot x - x\csc^2 x.

Example 3: a value. At x = \frac{\pi}{4}, \csc\frac{\pi}{4} = \sqrt{2}, so the slope is -(\sqrt{2})^2 = -2. The tangent line through \left(\frac{\pi}{4}, 1\right) is y = 1 - 2\left(x - \frac{\pi}{4}\right).

Example 4: the log of sine. \frac{d}{dx}\ln(\sin x) = \frac{\cos x}{\sin x} = \cot x. Differentiating again gives -\csc^2 x. This is why \int\cot x\,dx = \ln\lvert\sin x\rvert + C, see the integral of cot x.

How to remember it

Pair \cot x with \tan x. The derivative of tangent is \sec^2 x. Swap each function for its "co" partner, tangent to cotangent and secant to cosecant, then put a minus sign in front. That gives -\csc^2 x with no proof needed. The same swap works for every pair of trig derivatives, so you only need to memorize three of the six results. A quick graph check confirms the sign: each branch of cotangent falls from left to right, so its slope must always be negative. The steepness grows near the asymptotes at multiples of \pi, where \csc^2 x blows up.

Common mistakes

  1. Dropping the minus sign. Cotangent always decreases, so its derivative must be negative.
  2. Writing -\csc x\cot x. That is the derivative of csc x, a different result.
  3. Writing -\sec^2 x. The square goes on cosecant, the partner of secant.

For the whole family in one place, read derivatives of trig functions.

Practice it now

Sine, cosine and tangent

Solve real problems on this topic with instant feedback, hints and a step-by-step walkthrough for every answer. Free, no sign-up needed to start.

Practice this lesson

Frequently asked questions

What is the derivative of cot x?

The derivative of \cot x is -\csc^2 x = -\frac{1}{\sin^2 x}.

How do you prove the derivative of cot x?

Write \cot x = \frac{\cos x}{\sin x}. The quotient rule gives \frac{-\sin^2 x - \cos^2 x}{\sin^2 x} = -\frac{1}{\sin^2 x} = -\csc^2 x.

What is the derivative of cot(2x)?

By the chain rule, -2\csc^2(2x).

What is the derivative of cot²x?

It is 2\cot x\cdot(-\csc^2 x) = -2\cot x\csc^2 x.

Written by the PracticeCalculus team

We build interactive calculus lessons and write every page to be clear and correct. Spotted something off? Tell us and we will fix it.