Log Calculator (Logarithm)

Math Updated 30 Oct 2026

Calculates the logarithm of a number in any base: the power y to which the base b must be raised to give x, so that logb(x) = y means bʸ = x. Choose base 10 (common log), base e (natural log, ln), base 2 (binary log) or any other positive base. Alongside the answer you get the natural, common and binary logarithms of the same number and the change-of-base working, so you can check the result by hand or convert between bases.

  • Real-valued logarithms only.

Formula

log_b(x) = y ⇔ bʸ = x; change of base: log_b(x) = ln x ÷ ln b
  • ln is the natural logarithm with base e ≈ 2.718281828.
  • Rules: log(xy) = log x + log y, log(x/y) = log x − log y, log(xⁿ) = n log x.
  • x must be greater than zero, and the base positive and not 1.
  • Results are shown to about 12 significant figures.

log₁₀ of 1,000

Inputs
  • Number (x): 1000
  • Base: 10
  • Base (b): 3

10³ = 1,000, so log₁₀(1,000) = 3. The same number has ln(1,000) = 6.907755279 and log₂(1,000) = 9.965784285.

Sources & references

Frequently asked questions

What is a logarithm?
The inverse of an exponent. log_b(x) asks 'to what power must b be raised to get x?' Because 2⁵ = 32, log₂(32) = 5.
What is the difference between log and ln?
log usually means base 10 (in science and on calculators), while ln is the natural log with base e. In some maths texts and programming languages, log means ln.
How do I calculate a log in another base?
Use the change-of-base formula: log_b(x) = ln x ÷ ln b. For example log₃(81) = ln 81 ÷ ln 3 = 4.
Why can't I take the log of zero or a negative number?
A positive base raised to any real power is always positive, so no real power gives 0 or a negative number.

Related calculators