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
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)
| Name | Notation | Base | Typical Use |
|---|---|---|---|
| Common Log | log(x) | 10 | General math, engineering |
| Natural Log | ln(x) | e (≈2.718) | Calculus, growth/decay, continuous compounding |
| Binary Log | log₂(x) | 2 | Computer science, information theory |
| Custom Base Log | log_b(x) | b | Any 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
- 1Enter the number (x) you want to take the logarithm of.
- 2Optionally enter the base (b). If you leave it blank, the calculator uses base 10.
- 3To compute natural log, use base = e (or select ln if your UI supports it).
- 4Click calculate to get the result.
- 5Use the example table below to sanity-check your answer.
Worked Examples
| Expression | Result | Reason |
|---|---|---|
| log₁₀(100) | 2 | 10² = 100 |
| log₂(8) | 3 | 2³ = 8 |
| ln(e) | 1 | e¹ = e |
| log₁₀(1) | 0 | 10⁰ = 1 |
| log_b(b) | 1 | b¹ = b |
| log₂(1/8) | -3 | 2⁻³ = 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
log10(x) · values shown as provided
Log as the Inverse of Exponentiation
Logarithm Calculator FAQs
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.
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.
Why is log(1) always 0?
Because b^0 = 1 for any valid base b, so log_b(1) = 0.
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.
How do I compute log with a custom base?
Use the change-of-base formula: log_b(x) = ln(x) / ln(b).
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.
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.
What happens if x is between 0 and 1?
The log becomes negative. Example: log10(0.01) = -2 because 10^-2 = 0.01.
