Logarithm Calculator

Find log base b of x, ln, log₁₀ and log₂ of any positive number, or solve bʸ = x for x or for the base, with a check of the answer.

Reviewed · How we build and check our calculators

Your details

log base 3 of 81

4

3 to the power 4 is 81

ln x (base e)
4.394449
log₁₀ x
1.908485
log₂ x
6.33985
Change of base
ln 81 ÷ ln 3 = 4.394449 ÷ 1.098612
Check
3^4 = 81

81 is an exact whole-number power of 3: 3 to the power 4.

How the logarithm calculator works

Find the logarithm of any positive number in any base, with shortcuts for ln, log₁₀ and log₂. You can also solve bʸ = x for x or for the base b.

Formula

log_b(x) = y means bʸ = x. Change of base: log_b(x) = ln x ÷ ln b. Root: b = x^(1/y).

  1. 1

    Ask the question

    log base 3 of 81 asks: 3 to what power gives 81?

  2. 2

    Use the change of base

    ln 81 ÷ ln 3 = 4.394449 ÷ 1.098612 = 4.

  3. 3

    Check the answer

    3⁴ = 3 × 3 × 3 × 3 = 81, so log base 3 of 81 is 4.

  4. 4

    Compare other bases

    The same 81 has ln 81 = 4.394449, log₁₀ 81 = 1.908485 and log₂ 81 = 6.33985.

Worked example

The calculator opens with these values

Calculate
log base b of x (solve bʸ = x for y)
Base b
3
Number x
81

log base 3 of 81

4

Logarithms of common numbers

The logarithm of 1 is 0 in every base, numbers below 1 have negative logarithms, and each tenfold step adds exactly 1 to the common log. Use log₁₀ 2 ≈ 0.3010 and log₁₀ 3 ≈ 0.4771 to estimate many others by hand.

Natural, common and binary logarithms of common numbers
xln xlog₁₀ xlog₂ x
0.1-2.3026-1-3.3219
0.5-0.6931-0.301-1
1000
20.69310.3011
31.09860.47711.585
51.60940.6992.3219
102.302613.3219
1004.605226.6439
1,0006.907839.9658
1,0246.93153.010310

Rules for working with logarithms

These rules hold in any base. They turn multiplication into addition, which is why logarithms were invented.

  • Product: log(xy) = log x + log y. log₁₀ 200 = log₁₀ 2 + log₁₀ 100 = 0.301 + 2 = 2.301.
  • Quotient: log(x ÷ y) = log x − log y.
  • Power: log(xⁿ) = n × log x. log₂ 8³ = 3 × log₂ 8 = 3 × 3 = 9.
  • Reciprocal: log(1 ÷ x) = −log x, so log₁₀ 0.1 = −1.
  • Base and one: log_b(b) = 1 and log_b(1) = 0 for every valid base.

Where logarithms are used

Logarithmic scales squeeze huge ranges into small numbers, so one step means a fixed multiple.

  • pH: −log₁₀ of the hydrogen ion concentration. Each step down the scale is ten times more acidic.
  • Decibels: 10 × log₁₀ of a power ratio. +10 dB is ten times the sound power, and +3 dB is about double.
  • Earthquake magnitude: each whole step is ten times the measured ground motion and about 32 times the energy.
  • Bits: telling n options apart takes log₂ n bits, so 256 values need 8 bits.
  • Doubling time: money or a population growing 7% a year doubles in ln 2 ÷ ln 1.07 = 10.24 years.

Common questions

Why can't I take the logarithm of zero or a negative number?

A positive base raised to any real power is always positive, so no exponent gives zero or a negative number. The logarithm of x ≤ 0 is undefined among the real numbers.

Why can't the base be 1?

Every power of 1 is 1, so 1ʸ can never equal any other x, and log base 1 of 1 could be any number.

What is the difference between log and ln?

ln is the natural logarithm, base e ≈ 2.71828, used in growth and decay. log on its own usually means base 10 in school and engineering, though in computer science it often means base 2.

How do logarithms help solve equations?

They bring an unknown exponent down. To solve 2ʸ = 50, take logs: y = ln 50 ÷ ln 2 ≈ 5.643856.

Add this calculator to your website

Free for blogs, schools and businesses. Paste this code into your page; the calculator works inside it, with no ads and no tracking. Please keep the credit line.