Logarithm Calculator

Calculate log values with base 10, natural log (ln), or any custom base.

What is it?

A logarithm answers the question: to what power must the base be raised to produce a given number? This calculator computes logarithms with any base, plus quick shortcuts for base-10 (log₁₀) and natural log (ln).

Formula

log_b(x) = ln(x) / ln(b)

Formula Explanation

Most calculators, including this one, don't have a built-in function for every possible base, so the "change of base" formula converts any log_b(x) into a ratio of natural logs, which can always be computed directly.

Example Calculation

log10(100) = 2, since 10² = 100.

How to Use

  1. Enter the number you want the logarithm of.
  2. Enter the base (defaults to 10), or use the log₁₀ / ln quick buttons.
  3. View the calculated logarithm value.

Benefits

  • Supports any positive base, not just 10 or e.
  • One-click shortcuts for the two most common logarithm types.
  • Precise results to 6 decimal places.

Use Cases

  • Solving exponential growth or decay problems.
  • Computing pH, decibel, or Richter scale values, which are all logarithmic.
  • Homework or coursework involving logarithmic equations.

What Your Result Means

The result is the exponent that the base must be raised to in order to produce your entered number. For example, a result of 2 with base 10 means 10² equals your input number.

Tips

  • Use log₁₀ for scales like pH or decibels, which are conventionally base-10.
  • Use ln for natural growth/decay problems, like compound interest or radioactive decay.
  • A logarithm of a number between 0 and 1 is always negative.

Common Mistakes

  • Trying to take the logarithm of zero or a negative number, which is undefined.
  • Using a base of 1, which is invalid since 1 raised to any power is always 1.
  • Confusing log (commonly base 10) with ln (base e) when following a formula.

FAQs

Why must the number be positive?

Logarithms are only defined for positive real numbers — the logarithm of zero or a negative number is undefined in real-number math.

What's the difference between log and ln?

log (without a specified base) usually refers to base-10, while ln refers to the natural logarithm, which uses base e (≈2.71828).

Why can't the base be 1?

Raising 1 to any power always gives 1, so a base of 1 cannot produce any other number, making the logarithm undefined.

What does a negative logarithm result mean?

It means your input number is between 0 and 1 — for example, log₁₀(0.01) = -2, since 10⁻² = 0.01.

How are logarithms used in real life?

Logarithmic scales are used for measuring earthquake magnitude (Richter scale), sound intensity (decibels), and acidity (pH), among other applications.

Results are rounded to 6 decimal places.

Last updated: July 25, 2026