# Derivative of cos x: Formula, Proof and Examples

> The derivative of cos x is -sin x. See the limit proof, a quick proof from sin x, the chain rule for cos(u) and worked examples like cos(5x).

Source: https://practicecalculus.com/derivatives/cos-x
Updated: 2026-11-06

$$ \frac{d}{dx}\,\cos x = -\sin x $$

## At a glance

- **Derivative:** $-\sin x$ for every real $x$
- **Chain rule form:** $\dfrac{d}{dx}\cos u = -\sin u \cdot u'$
- **Second derivative:** $-\cos x$
- **Units:** $x$ must be in radians
- **Integral version:** $\int \cos x\,dx = \sin x + C$

## Key takeaways

- The derivative of $\cos x$ is $-\sin x$. Do not drop the minus sign.
- With the chain rule, $\frac{d}{dx}\cos u = -\sin u \cdot u'$.
- Every "co" function (cos, cot, csc) has a minus sign in its derivative.
- The four derivatives of $\cos x$ cycle: $-\sin x$, $-\cos x$, $\sin x$, $\cos x$.

The **derivative of $\cos x$ is $-\sin x$**. Cosine starts at its peak at $x = 0$ and heads down, so its slope for small positive $x$ is negative, matching $-\sin x < 0$.

$$\frac{d}{dx}\,\cos x = -\sin x$$

## Graph of cos x and its derivative

```graph
title: 'Graph of y = cos x and its derivative y = -sin x'
caption: 'Where $\cos x$ falls, $-\sin x$ is below the axis. At the peak $x = 0$ the slope is $0$, and at $x = \frac{\pi}{2}$ the slope is $-1$.'
x: [-6.5, 6.5]
y: [-1.8, 1.8]
functions:
  - expr: cos(x)
    label: y = cos x
  - expr: -sin(x)
    label: y = -sin x (derivative)
    dashed: true
points:
  - [0, 1, 'peak, slope 0']
  - [1.5708, 0, 'slope -1']
```

## Proof from the limit definition

The angle sum formula gives $\cos(x + h) = \cos x\cos h - \sin x\sin h$. So

$$\frac{\cos(x + h) - \cos x}{h} = \cos x\cdot\frac{\cos h - 1}{h} - \sin x\cdot\frac{\sin h}{h}$$

With $\frac{\cos h - 1}{h} \to 0$ and $\frac{\sin h}{h} \to 1$:

$$\frac{d}{dx}\cos x = \cos x\cdot 0 - \sin x\cdot 1 = -\sin x$$

## A quicker proof using sin x

Write $\cos x = \sin\left(\frac{\pi}{2} - x\right)$. Then by the [chain rule](/rules/chain-rule) and the [derivative of sin x](/derivatives/sin-x):

$$\frac{d}{dx}\cos x = \cos\left(\frac{\pi}{2} - x\right)\cdot(-1) = -\sin x$$

using $\cos\left(\frac{\pi}{2} - x\right) = \sin x$. The $-1$ from the inside is where the minus sign comes from.

## The chain rule version: derivative of cos(u)

$$\frac{d}{dx}\,\cos u = -\sin u\cdot u'$$

| Function | Inside $u$ | Derivative |
| --- | --- | --- |
| $\cos(5x)$ | $5x$ | $-5\sin(5x)$ |
| $\cos(x^3)$ | $x^3$ | $-3x^2\sin(x^3)$ |
| $\cos(1 - x)$ | $1 - x$ | $\sin(1 - x)$ |
| $\cos(\ln x)$ | $\ln x$ | $-\frac{\sin(\ln x)}{x}$ |

In the third row two minus signs cancel.

## Worked examples

**Example 1: a product.** $\frac{d}{dx}\left(e^x\cos x\right) = e^x\cos x - e^x\sin x = e^x(\cos x - \sin x)$, by the [product rule](/rules/product-rule).

**Example 2: a quotient.** $\frac{d}{dx}\frac{\cos x}{x} = \frac{-x\sin x - \cos x}{x^2}$, by the [quotient rule](/rules/quotient-rule).

**Example 3: motion.** A spring's position is $s(t) = 4\cos(2t)$. Its velocity is $v(t) = -8\sin(2t)$ and its acceleration is $a(t) = -16\cos(2t) = -4s(t)$. Acceleration always points back toward the center.

**Example 4: a horizontal tangent.** $\frac{d}{dx}(x + 2\cos x) = 1 - 2\sin x$. It equals $0$ when $\sin x = \frac{1}{2}$, so at $x = \frac{\pi}{6}$ and $x = \frac{5\pi}{6}$ in $[0, 2\pi)$.

## How to remember the sign

Picture the unit circle. Cosine is the horizontal coordinate. As the angle grows from $0$, the point moves up and to the left, so the horizontal coordinate shrinks. A shrinking quantity has a negative rate of change, which is why the derivative is $-\sin x$ and not $+\sin x$.

## Common mistakes

1. **Dropping the minus sign.** This is the most common trig derivative error. Remember: "co" functions get a minus.
2. **Double minus confusion.** $\frac{d}{dx}(-\cos x) = \sin x$, positive.
3. **Forgetting $u'$.** $\frac{d}{dx}\cos(4x) = -4\sin(4x)$, not $-\sin(4x)$.

The reverse is on the [integral of cos x](/integrals/cos-x) page. The [cosine function](/functions/cosine-function) page covers its graph and key values.

## Frequently asked questions

### What is the derivative of cos x?

The derivative of $\cos x$ is $-\sin x$.

### What is the derivative of cos(2x)?

By the chain rule, $-\sin(2x) \cdot 2 = -2\sin(2x)$.

### Why is the derivative of cos x negative?

Just right of $x = 0$, cosine starts to fall from its peak while sine is positive. A falling curve has a negative slope, so the derivative must be $-\sin x$, not $\sin x$.

### What is the derivative of cos²x?

It is $2\cos x \cdot(-\sin x) = -2\sin x\cos x = -\sin 2x$.
