Logarithm Calculator: Log Base 10, 2 & e

Calculate logarithms with any base (default base 10).

Logarithm Calculator

Calculate logarithm of a number with any base

Enter positive numbers. Base cannot be 1.

Quick Tips

  • • Common bases: 10 (log₁₀), e (ln ≈ 2.718), 2 (log₂)
  • • logₐ(b) tells you: a to what power equals b?
  • • logₐ(1) = 0 for any base a

What is a Logarithm?

A logarithm answers this question: what exponent makes the base turn into the number? If by = x, then y = logb(x). Logs are used to work with numbers that scale exponentially, like sound intensity, earthquakes, data growth, pH, and finance.

Common Log Types (Quick Guide)

NameNotationBaseTypical Use
Common Loglog(x)10General math, engineering
Natural Logln(x)e (≈2.718)Calculus, growth/decay, continuous compounding
Binary Loglog₂(x)2Computer science, information theory
Custom Base Loglog_b(x)bAny base you choose

Core Formula

y = logb(x) is equivalent to by = x. Example: log10(100) = 2 because 102 = 100.

How to Use the Log Calculator

  1. 1
    Enter the number (x) you want to take the logarithm of.
  2. 2
    Optionally enter the base (b). If you leave it blank, the calculator uses base 10.
  3. 3
    To compute natural log, use base = e (or select ln if your UI supports it).
  4. 4
    Click calculate to get the result.
  5. 5
    Use the example table below to sanity-check your answer.

Worked Examples

ExpressionResultReason
log₁₀(100)210² = 100
log₂(8)32³ = 8
ln(e)1e¹ = e
log₁₀(1)010⁰ = 1
log_b(b)1b¹ = b
log₂(1/8)-32⁻³ = 1/8

Log Rules You Should Know

  • Product rule: log_b(xy) = log_b(x) + log_b(y)
  • Quotient rule: log_b(x/y) = log_b(x) − log_b(y)
  • Power rule: log_b(x^k) = k · log_b(x)
  • log_b(1) = 0
  • log_b(b) = 1
  • Change of base: log_b(x) = ln(x) / ln(b)

Domain rule: For real-number logs, x must be greater than 0. Also the base must satisfy b > 0 and b ≠ 1.

Change of Base Formula (Most Useful Trick)

If your calculator only supports ln or log base 10, you can still compute any base using: logb(x) = ln(x) / ln(b). Example: log3(81) = ln(81)/ln(3) = 4 because 3⁴ = 81.

How Logs Grow Slowly (Intuition)

log10(x) Values for Common Powers of 10

1
0
10
1
100
2
1,000
3
10,000
4
100,000
5
1,000,000
6

log10(x) · values shown as provided

Log as the Inverse of Exponentiation

Logs undo exponentiation: if b^y = x, then y = log_b(x).

Logarithm Calculator FAQs

Q

What is the natural log (ln)?

The natural logarithm uses base e (approximately 2.718). It appears everywhere in growth/decay, calculus, and continuous compounding.

Q

Can I calculate log of a negative number?

Not in real numbers. Real logs require x > 0. In complex numbers, logs exist but the output involves imaginary components.

Q

Why is log(1) always 0?

Because b^0 = 1 for any valid base b, so log_b(1) = 0.

Q

Why can’t the base be 1?

Because 1^y is always 1, so it can’t produce different x values. That makes log base 1 undefined.

Q

How do I compute log with a custom base?

Use the change-of-base formula: log_b(x) = ln(x) / ln(b).

Q

What is log base 2 used for?

Log base 2 is common in computing because it measures growth in powers of 2, like bits, memory sizes, and algorithm complexity.

Q

Is log base 10 the same as ln?

No. log base 10 uses base 10, while ln uses base e. They grow at different rates.

Q

What happens if x is between 0 and 1?

The log becomes negative. Example: log10(0.01) = -2 because 10^-2 = 0.01.