practicecalculus
Exponential and log derivatives

Derivative of 2ˣ and aˣ: Formula, Proof and Examples

The derivative of 2ˣ is 2ˣ ln 2, and of aˣ is aˣ ln a. See the proof by rewriting aˣ as e^(x ln a), chain rule examples and a graph.

Exponential and log derivatives Updated 2 min read

At a glance

\frac{d}{dx}\,2^x = 2^x\ln 2
Derivative of 2ˣ
2^x\ln 2 \approx 0.693\cdot 2^x
General base
\dfrac{d}{dx}a^x = a^x\ln a for a > 0
Chain rule form
\dfrac{d}{dx}a^u = a^u\ln a\cdot u'
Key rewrite
a^x = e^{x\ln a}
Integral version
\int 2^x\,dx = \dfrac{2^x}{\ln 2} + C
On this page
  1. Graph of 2ˣ and its derivative
  2. Proof: rewrite with base e
  3. The size of the factor ln a
  4. Chain rule version and examples
  5. 2ˣ versus x²
  6. Common mistakes

The derivative of 2^x is 2^x\ln 2. The same pattern works for every positive base:

\frac{d}{dx}\,2^x = 2^x\ln 2 \qquad\qquad \frac{d}{dx}\,a^x = a^x\ln a

Since \ln 2 \approx 0.693, the slope of 2^x is always about 69\% of its height.

Graph of 2ˣ and its derivative

Graph of y = 2ˣ and its derivative y = 2ˣ ln 2
The derivative has the same shape as 2^x, scaled down by \ln 2 \approx 0.693. At x = 0 the function is 1 and the slope is \ln 2.

Proof: rewrite with base e

Any positive base can be written as a power of e, because a = e^{\ln a}:

a^x = \left(e^{\ln a}\right)^x = e^{x\ln a}

Now \ln a is just a constant, so the chain rule with the derivative of eˣ gives

\frac{d}{dx}e^{x\ln a} = e^{x\ln a}\cdot\ln a = a^x\ln a

For a = 2 this is 2^x\ln 2. For a = e it is e^x\ln e = e^x, which is why e is the natural base: it is the only base with no extra factor.

The size of the factor ln a

Base a \ln a Derivative of a^x
2 \approx 0.693 2^x\ln 2
e 1 e^x
3 \approx 1.099 3^x\ln 3
10 \approx 2.303 10^x\ln 10
\frac{1}{2} \approx -0.693 -\left(\frac{1}{2}\right)^x\ln 2

For 0 < a < 1, \ln a is negative, so a^x is decreasing. That matches the graph of exponential decay.

Chain rule version and examples

\frac{d}{dx}a^u = a^u\ln a\cdot u'

Example 1. \frac{d}{dx}2^{3x} = 2^{3x}\ln 2\cdot 3 = 3\ln 2\cdot 2^{3x}.

Example 2. \frac{d}{dx}3^{x^2} = 3^{x^2}\ln 3\cdot 2x = 2x\ln 3\cdot 3^{x^2}.

Example 3. \frac{d}{dx}2^{-x} = -2^{-x}\ln 2.

Example 4: product rule. For f(x) = x\cdot 2^x, the product rule gives

f'(x) = 2^x + x\cdot 2^x\ln 2 = 2^x(1 + x\ln 2)

Example 5: growth rate. A population P(t) = 500\cdot 2^t doubles every unit of time. Its growth rate at t = 3 is P'(3) = 500\cdot 8\ln 2 \approx 2773 per unit time.

2ˣ versus x²

Function Base Exponent Rule Derivative
x^2 variable constant power rule 2x
2^x constant variable exponential rule 2^x\ln 2
x^x variable variable logarithmic differentiation x^x(\ln x + 1)

When both base and exponent vary, neither rule applies on its own. See the derivative of xˣ.

Common mistakes

  1. Using the power rule: x\cdot 2^{x-1}. Wrong rule for a variable exponent.
  2. Leaving out \ln 2. That would be correct only for base e.
  3. Writing \log 2 instead of \ln 2. The factor is the natural log.

The reverse, \int 2^x\,dx = \frac{2^x}{\ln 2} + C, is on the integral of 2ˣ page. The inverse function, \log_2 x, is covered on the derivative of log x page. See also exponential functions.

Practice it now

Exponentials and logarithms

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 2^x?

The derivative of 2^x is 2^x\ln 2, which is about 0.693\cdot 2^x.

What is the derivative of a^x?

For any constant a > 0, \frac{d}{dx}a^x = a^x\ln a. For example, \frac{d}{dx}10^x = 10^x\ln 10 and \frac{d}{dx}3^x = 3^x\ln 3.

Why is the derivative of 2^x not x·2^(x−1)?

That is the power rule, which needs a variable base and a constant exponent. In 2^x the base is constant and the exponent is the variable, so you use the exponential rule instead.

What is the derivative of 2^(3x)?

By the chain rule, 2^{3x}\ln 2\cdot 3 = 3\ln 2\cdot 2^{3x}.

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.