Derivative calculator

Type a function of x, such as x^3 * sin(x), choose the order and an optional point. The tool differentiates it symbolically and shows the result in text you can copy back into the box.

Use x, numbers, + - * / ^, parentheses, pi, e and sin(x), cos(x), tan(x), exp(x), ln(x), log(x) (base 10), sqrt(x), abs(x). Write 2x or 2*x. Angles are in radians.
A number or constant such as 2, -1.5 or pi/4. Leave empty to skip.
Derivative3 * x^2 * sin(x) + x^3 * cos(x)
f(a)
7.274379415
Derivative at a
7.58239443

Runs in your browser: nothing you enter is sent anywhere.

How to use it

  1. Type f(x). Multiplication can be written 2x, 2*x or 2 × x; functions need brackets, as in sin(x).
  2. Pick the order, from first to fourth.
  3. Optionally enter a point a to get f(a) and the derivative’s value there.

How it works

The text is parsed into an expression tree, which is differentiated node by node: (u + v)′ = u′ + v′, (uv)′ = u′v + uv′, (u / v)′ = (u′v − uv′) / v², and the chain rule multiplies by the derivative of the inside. The result is simplified a little and printed. Higher orders repeat the step. The point value is a plain numeric evaluation of the printed tree.

Worked example

f(x) = x^3 * sin(x). By the product rule f′(x) = 3x² sin x + x³ cos x, which the tool prints as 3 * x^2 * sin(x) + x^3 * cos(x). At x = 2 this is 12 sin 2 + 8 cos 2 ≈ 7.582395, while f(2) = 8 sin 2 ≈ 7.274379.

Tips

  • Compare with a quick check: f(a + h) − f(a − h) over 2h for a small h should be close to f′(a).
  • Use ln(x) for natural logs; log(x) is base 10.
  • Only the variable x is supported.

Frequently asked questions

Which rules does the calculator use?

It applies the sum, product, quotient and chain rules, the power rule for constant exponents, the rule for a constant raised to a variable power, and the general rule for expressions like x^x. The derivatives of sin, cos, tan, exp, ln, log, sqrt and abs are built in.

Why does the answer look different from my textbook?

Simplification is light on purpose: it removes zeros and ones, folds numbers and combines signs, but it does not factor or use identities. Two forms that look different are equal if they give the same value, which you can check with the point box.

What happens at points where the derivative does not exist?

The value row says it is not defined. For abs(x) the derivative is written as x / abs(x), which does not exist at 0, where the function has a corner.

Is log base 10 or natural?

log(x) is base 10 and ln(x) is the natural logarithm. The derivative of log(x) is 1 / (x * 2.302585…), where 2.302585 is ln 10.

More in Math

All tools in this category: Math ·Updated November 3, 2026

Privacy choices

Google Analytics shows us which tools are used and whether they work. It may set cookies. Your choice is kept in this browser.