Logarithm Calculator
Calculate the logarithm of any positive number in base 10, base e, base 2 or any other base, with the change-of-base steps.
log(1000)
3
- ln
- 6.907755279
- log₁₀
- 3
- log₂
- 9.9657842847
Steps
- 1Use the change-of-base formula: log(1000) = ln(1000) / ln(10) = 6.90775528 / 2.30258509
- 2The result is exact: 10³ = 1000
About this tool
A logarithm answers the question: to what power must the base be raised to get this number? log₁₀(1000) = 3 because 10³ = 1,000, and log₂(8) = 3 because 2³ = 8. It's the inverse of the power function: if bʸ = x, then y = log_b(x). The number x must be positive, and the base must be positive and different from 1.
Three bases are used most. The common logarithm (base 10, written log or lg) counts orders of magnitude: log₁₀(5000) ≈ 3.69897, because 5,000 lies between 10³ and 10⁴. The natural logarithm (base e ≈ 2.718282, written ln) appears in growth, decay and calculus. The binary logarithm (base 2) is used in computing: log₂(1024) = 10, so 1,024 different values need 10 bits.
Calculators usually only have ln and log keys, so other bases go through the change-of-base formula: log_b(x) = ln(x) / ln(b). For example, log₂(1000) = 6.907755 / 0.693147 ≈ 9.965784. Logarithms also turn multiplications into additions, log(a × b) = log(a) + log(b), which is why they're used for scales such as pH, decibels and earthquake magnitudes.
Worked example
- 1Enter the number x, which must be greater than 0.
- 2Choose the base: 10, e, 2 or another base.
- 3Read the result, the values of ln, log₁₀ and log₂, and the check. Example: log₃(81) = 4 because 3⁴ = 81.
Formula
log_b(x) = y ⇔ bʸ = x ; log_b(x) = ln(x) / ln(b) ; log(a × b) = log(a) + log(b) ; log(aⁿ) = n × log(a)
Related tools
Frequently asked questions
- What's the difference between log and ln?
- log usually means the base-10 logarithm, and ln the natural logarithm, in base e ≈ 2.718282. They differ by a constant factor: ln(x) = ln(10) × log₁₀(x) ≈ 2.302585 × log₁₀(x). In some programming languages and advanced math texts, log means ln, so check the convention.
- Why can't you take the logarithm of 0 or a negative number?
- Because no power of a positive base gives 0 or a negative number: bʸ is always positive. As x gets closer to 0, log(x) heads toward minus infinity. Logarithms of negative numbers only exist among complex numbers.
- How do I use a logarithm to find a doubling time?
- For an investment growing by 5% a year, solve 1.05ⁿ = 2: n = ln(2) / ln(1.05) ≈ 14.2 years. The same method gives the half-life of a substance or the time needed to reach any growth target.
- What is the logarithm of 1?
- In any base, log_b(1) = 0, because b⁰ = 1. Likewise, log_b(b) = 1: log₁₀(10) = 1 and ln(e) = 1.