Logarithm Calculator
Logarithms to any base — log₁₀, natural log (ln), log₂ and a base of your choice — with the antilog check.
log_b(x) is the exponent that b must be raized to in order to give x: log₁₀(1000) = 3 because 10³ = 1000.
How the logarithm calculator works
log_b(x) is the exponent that b must be raized to in order to give x: log₁₀(1000) = 3 because 10³ = 1000. Any base is computed by the change-of-base rule log_b(x) = ln(x) ÷ ln(b). Logarithms are only defined for positive x.
Formula: log_b(x) = ln(x) / ln(b)
Worked examples
| Inputs | log base b of x | Note |
|---|---|---|
| log₁₀ 1000 | 3 | 3 |
| log₂ 1024 | 10 | 10 |
| ln 20 (base e) | 2.9957322736 | 2.9957 |
FAQFrequently asked questions
What is a logarithm?
The power you raize the base to in order to get the number. Because 2¹⁰ = 1024, log₂ 1024 = 10.
What is the difference between log and ln?
log usually means base 10; ln is the natural logarithm, base e ≈ 2.71828, which appears in continuous growth and decay.
Why can't I take the log of a negative number?
No real power of a positive base gives a negative result. Logs of zero and negatives are undefined in real numbers.
How do I find a log in a base my calculator lacks?
Change of base: log_b(x) = log(x) ÷ log(b) using any log button.
Where are logarithms used?
Decibels, pH, the Richter scale, doubling times, compound growth ("how many years to double?") and information theory (bits).
Where these figures come from
- NIST Digital Library of Mathematical Functions — reference definitions for elementary and special functions
- Wolfram MathWorld — definitions and formulas for every topic on this page
- NIST/SEMATECH e-Handbook of Statistical Methods — the statistical formulas (mean, variance, z, confidence intervals, sample size)
- Common Core State Standards — Mathematics — the terms and methods taught in US schools
Last checked: September 2026. Formulas are fixed by mathematics and do not change with tax years or regulations.