Math · Algebra Formula verified

Logarithm Calculator

Enter a value and a base to find log_b(x) — natural log (base e) and common log (base 10) are shown alongside as quick reference.

log_b(x)
05001000
11836
On-screen number pad
Tap to type into the highlighted field
log₂(8)
3
2³ = 8
Natural log (ln)
2.0794
Common log (log₁₀)
0.9031

Step-by-step proofCheck by hand

How the change-of-base formula works

log_b(x) asks: what power do you raise b to, to get x? There's no native "logarithm to any base" function in most software, so this calculator uses the change-of-base identity — log_b(x) = ln(x) ÷ ln(b) — to compute it from natural log, which is built in.

The formula

log_b(x) = ln(x) ÷ ln(b)

Worked example

log₂(8): ln(8) ÷ ln(2) ≈ 2.0794 ÷ 0.6931 = 3, since 2³ = 8.

Frequently asked questions

What is a logarithm?
A logarithm answers the question "what power do I need to raise the base to, to get this number?" logb(x) = y means by = x. Logarithms are the inverse operation of exponentiation, the same way division is the inverse of multiplication.
How does the change-of-base formula work?
Most calculators (and this one) only have natural log (ln) and log base 10 built in as native functions. The change-of-base formula, logb(x) = ln(x) ÷ ln(b), lets you compute a logarithm to any base from either of those, since the ratio of two logarithms in the same base always equals the logarithm in the original base.
Why is there no logarithm of a negative number or zero?
Because no real power of a positive base ever produces zero or a negative number — by is always positive for a positive base b, however large or small (even negative) the exponent y gets. Logarithms of negative numbers exist in the complex numbers, but that's outside what this calculator computes.
Sources and method
  • Standard published mathematics — logarithms and the change-of-base formula.
Last reviewed: 20 Sep 2026 Sources last verified: 20 Sep 2026 Results use the assumptions explained on this page. Report an error How we check calculations

Related calculators