Logarithm Calculator (log, ln, log2, any base)
Logarithms in any base, natural log, log base 2 and antilogs, with steps.
log_b(x) is the power you raise b to get x. Use change of base: log_b(x) = ln(x) ÷ ln(b). log₁₀(1000) = 3, log₂(64) = 6 and ln(10) = 2.302585.
Free, runs in your browser. Nothing you enter is uploaded.
How to use it
- Choose logarithm or antilog.
- Enter the number and the base, or tap base 10, e or 2.
- Read the result and the common-base values.
What you enter
- Number
- Base
What you get
- log in chosen base
- log₁₀, ln and log₂
Formula
log_b(x) = ln(x) ÷ ln(b) | antilog_b(y) = b^y
Worked example
Input: x = 64, base 2
Result: log₂(64) = 6
2⁶ = 64. Logs of this kind count doublings, as in bacterial growth.
Questions
What is a logarithm?
The exponent that turns the base into the number. log₁₀(100) = 2 because 10² = 100.
What is the difference between log and ln?
log usually means base 10 and ln means base e (≈ 2.71828). ln(x) = 2.302585 × log₁₀(x).
How do I calculate a log with a different base?
Divide the natural log (or log₁₀) of the number by that of the base: log₅(125) = ln(125) ÷ ln(5) = 3.
Why can't you take the log of zero or a negative number?
No real power of a positive base gives zero or a negative number, so those logs are undefined in real numbers.
Limitations
- Real-valued logs only; x and the base must be positive and the base cannot be 1.
References
More STEM & Mathematics
All free tools · By Dr. Zubair Khalid, DVM, MS, PhD.