The change of base formula, explained

By MathSolver Editorial Team · Published October 8, 2026 · Updated October 8, 2026

Published October 2026.

Your calculator has buttons for log (base 10) and ln (base e), but nothing for log₂, log₅, or log₇. The change of base formula bridges the gap: it rewrites any logarithm as a ratio of two logarithms your calculator does have.

The formula

logb(x) = logc(x) ÷ logc(b), for any convenient base c (usually 10 or e).

In the most-used form: logb(x) = ln(x) ÷ ln(b).

Why it works, in one line: if y = logb(x), then by = x; take logc of both sides, y·logc(b) = logc(x), and divide. The unknown base b migrates into a plain division.

Worked examples

Example 1. log₂(32): ln(32) ÷ ln(2) ≈ 3.4657 ÷ 0.6931 ≈ 5. (Sanity: 2⁵ = 32. ✓) Verify with our logarithm calculator.

Example 2. log₅(100): ln(100) ÷ ln(5) ≈ 4.6052 ÷ 1.6094 ≈ 2.861. Check: 5^2.861 ≈ 100. ✓

Example 3, solving an equation. 3x = 50 → x = log₃(50) = ln(50) ÷ ln(3) ≈ 3.9120 ÷ 1.0986 ≈ 3.561. This is the standard move for exponential equations with an awkward base.

Which base c should you pick?

Whichever your tool computes fastest, it genuinely does not matter. ln/ln and log/log give identical results (try both; the tiny last-digit differences are floating-point noise). On a basic calculator, log (base 10) is one button; in code, natural log is the default. Pick one and be consistent.

Common mistakes

Dividing in the wrong order: it is ln(x) ÷ ln(b), the argument on top, the base below. Flipping gives the reciprocal.

logb(x) ≠ ln(x) − ln(b): the formula is a ratio, not a difference. (ln x − ln b = ln(x/b), a different animal.)

Forgetting domain: x must be positive and b must be positive and ≠ 1, change of base cannot rescue an undefined logarithm.

Estimating logs mentally with change of base

Change of base also powers mental estimates. Need log₂(100)? You know 2⁶ = 64 and 2⁷ = 128, so the answer sits between 6 and 7, closer to 7, the exact value is ≈ 6.64. For log₁₀ of anything, count digits: log₁₀(5000) ≈ 3.7 because 10³ = 1000 and 10⁴ = 10000. These bracket-and-refine estimates catch calculator typos: if your change-of-base computation says log₂(100) = 66.4, the mental bracket tells you a decimal point slipped.

Bonus: proving log laws with change of base

Change of base makes the logarithm laws nearly trivial. Product law: log_b(xy) = ln(xy)/ln(b) = (ln x + ln y)/ln(b) = ln(x)/ln(b) + ln(y)/ln(b) = log_b(x) + log_b(y). The product law for exotic bases inherits directly from the natural-log product law, change of base is the bridge. Similarly the power law: log_b(x^n) = ln(x^n)/ln(b) = n·ln(x)/ln(b) = n·log_b(x). One formula, and the whole log toolkit follows.

Base-flip identity: log_b(a) = 1 / log_a(b). Proof: ln(a)/ln(b) = 1 ÷ (ln(b)/ln(a)). Handy when a problem gives you the “wrong direction” logarithm.

Cheat sheet

log_b(x) = ln(x) / ln(b) (or log(x)/log(b), same answer). Base-flip: log_b(a) = 1 / log_a(b). Power law via change of base: log_b(x^n) = n * log_b(x). Mental bracket: 2^6=64 < 100 < 128=2^7, so log2(100) is between 6 and 7.

Keep learning

Logarithms reward the patient. Our logarithms without fear guide covers the three rules that solve 90% of log problems, and the logarithm calculator evaluates any base with change-of-base steps shown. For the exponential side of the same coin, the universal solver handles equations like 2^x = 50 directly.

Why natural logs win in calculus

Change of base reveals why calculus prefers ln: the derivative of log_b(x) is 1/(x·ln b), the ln b is an artifact of the base. With base e, ln b = 1 and the derivative is cleanly 1/x. Every base-b log is just a scaled natural log, and change of base is the scaling formula. This is also why slide rules and log tables only needed one base: change of base extends a single table to every base. Master this one formula and every logarithm, whatever the base, becomes two button presses and a division.

A final tip: when a problem asks for an exact answer, leave it as a logarithm (like log_2(100)) rather than decimalizing. Exact forms preserve full precision through subsequent steps; round only the final answer. This habit separates strong students from calculators-with-legs. Exact first, approximate last, always. Your future self, checking work at midnight before an exam, will thank you profusely. And when the base is e or 10, skip change of base entirely, use ln or log directly without conversion. Simplicity beats cleverness in timed work, every single time.

Practice: test yourself

1. Compute log₄(64) via change of base. (ln 64 ÷ ln 4 ≈ 4.1589 ÷ 1.3863 = 3; check 4³ = 64 ✓.)
2. Solve 5x = 1000. (x = ln 1000 ÷ ln 5 ≈ 6.9078 ÷ 1.6094 ≈ 4.29.)
3. Which is bigger, log₂(100) or log₃(200)? (6.64 vs 4.82 → log₂(100). Smaller base grows slower, so it needs a bigger exponent.)

Frequently asked questions

log_b(x) = log_c(x) ÷ log_c(b) for any positive c ≠ 1. Most often written with natural logs: log_b(x) = ln(x) ÷ ln(b).

Use change of base: log₂(x) = ln(x) ÷ ln(2), or log(x) ÷ log(2) with base-10 logs. For x = 32: ln(32) ÷ ln(2) ≈ 5.

Set y = log_b(x), so b^y = x. Take log_c of both sides: y·log_c(b) = log_c(x). Divide by log_c(b) and y is isolated, that y is exactly log_b(x).

Yes. log_b(x) = log(x) ÷ log(b) with common logs gives the same answer. Use whichever button your calculator has; the math is base-independent.