Enter a function to find its first through fifth derivative. See the exact symbolic result, every differentiation rule used, an optional value at a point, and a graph of f and its derivative—all calculated locally in your browser.
Enter a function
Use ^ for powers. Supported: sin, cos, tan, sec, csc, cot, asin, acos, atan, sinh, cosh, tanh, sech, exp, ln, log, sqrt, and abs.
Try an example
Keyboard shortcut: Ctrl/⌘ + Enter.
Derivative
Original function
Enter a function to begin.
First derivative
The exact derivative will appear here.
Step-by-step differentiation
Rule-by-rule working will appear here.
Function and derivative graph
ff′
Differentiate a function to draw both curves. Gaps indicate undefined or non-real values.
Calculator methodology and review
Developed and reviewed by
Starlight Robotics calculator team
Last reviewed
Method
Tokenize → parse expression tree → apply symbolic differentiation rules recursively → simplify → evaluate and graph.
Input limits
One selected variable, 300 characters, derivative orders 1–5, real-valued graphing.
Privacy
The expression and results remain in your browser; the calculator does not call a solving API.
Important domains
Division, roots, logarithms, inverse trig functions and absolute value can restrict where a real derivative exists.
How to use the derivative calculator
Enter a function such as x^3*sin(x), ln(x^2+1), or e^(2x).
Select the variable and choose a derivative order from first through fifth.
Optionally enter a point to evaluate the final derivative there.
Select Differentiate, then review the simplified result, applied rules and graph.
Multiplication may be explicit or implicit: 2*x, 2x, and 3(x+1) are accepted. Function names require parentheses, such as sin(x). Trigonometric inputs use radians.
Rules supported by this calculator
Power and linearity rules
Constants become zero, sums are differentiated term by term, and u^n becomes n·u^(n−1)·u′.
Product and quotient rules
Products use (uv)′=u′v+uv′. Quotients use (u/v)′=(u′v−uv′)/v².
Chain rule
Composite functions differentiate from the outside inward, multiplying by the derivative of each inner function.
Common functions
Trigonometric, inverse trigonometric, hyperbolic, exponential, natural/base-10 logarithm, square-root and absolute-value rules are included.
Worked derivative examples
Polynomial
f(x)=4x³−5x+7
Differentiate term by term: f′(x)=12x²−5.
Product rule
f(x)=x³sin(x)
Let u=x³ and v=sin(x). Then f′(x)=3x²sin(x)+x³cos(x).
Chain rule
f(x)=ln(x²+1)
The outer derivative is 1/(x²+1); multiply by 2x, giving 2x/(x²+1).
Quotient rule
f(x)=(x²+1)/(x−1)
f′(x)=[2x(x−1)−(x²+1)]/(x−1)², valid for x≠1.
Derivative calculator FAQs
Which differentiation rules does the calculator use?
It applies constant, linearity, product, quotient, power and chain rules, along with rules for every supported named function.
Can it calculate second and higher derivatives?
Yes. Choose the second, third, fourth or fifth derivative. The calculator differentiates and simplifies successively, preserving steps for each order.
Can I enter 2x instead of 2*x?
Yes. Implicit multiplication is supported between numbers, variables and parentheses. Both 2x and 3(x+1) work.
Are trigonometric inputs in degrees or radians?
Radians. This matches standard calculus derivative formulas such as d[sin(x)]/dx=cos(x).
Why can the graph have gaps?
A gap means the function or derivative is undefined or non-real there. Common causes include division by zero, negative inputs to an even root, and logarithms of non-positive values.
Is the derivative of abs(x) defined at zero?
No. The calculator returns the formula x/abs(x), which applies away from zero. The original absolute-value function has a sharp corner at zero.
Does my expression leave the browser?
No. The local JavaScript engine performs parsing, differentiation, simplification, evaluation and graphing on your device.