Calculate logarithms in any base: common (log₁₀), natural (ln), binary (log₂), or custom base. Shows step-by-step change-of-base working, antilog (inverse), log laws reference, and a comparison table of log values across multiple bases simultaneously.
Type the number you want to find the logarithm of (must be positive). Then choose a base: log₁₀ (common), ln (natural, base e), log₂ (binary), or type any custom base. The result and full working appear instantly.
The change-of-base formula is shown: log_b(x) = ln(x)/ln(b). Each step is shown with the actual computed values. For common cases (log₁₀, ln, log₂), the direct formula is also displayed. Integer results are detected and shown as exact values.
The comparison table shows the logarithm of your number in bases 2, e, 10, and your custom base simultaneously. The antilog section lets you reverse the process: enter a log value and get back the original number (b^log = x).
A logarithm answers the question: "To what power must I raise a base to get a given number?" log_b(x) = y means b^y = x. For example: log₁₀(1000) = 3 because 10³ = 1000. ln(e²) = 2 because e² = e². log₂(32) = 5 because 2⁵ = 32. Logarithms are the inverse operation of exponentiation. They convert multiplication into addition (log(A×B) = log(A) + log(B)) and exponentiation into multiplication (log(Aⁿ) = n×log(A)), which historically made complex calculations manageable before calculators.
log (common logarithm) uses base 10. Used in pH, decibels (dB), Richter scale, and general mathematics. log₁₀(100) = 2. ln (natural logarithm) uses base e ≈ 2.71828. Essential in calculus, compound interest, exponential growth/decay, and physics. ln(e³) = 3. log₂ (binary logarithm) uses base 2. Critical in computer science: the number of bits needed to represent n values is ⌈log₂(n)⌉. log₂(1024) = 10 (1024 = 2¹⁰ = 1 KB). The change-of-base formula converts between them: log_b(x) = ln(x)/ln(b).
Product rule: log_b(MN) = log_b(M) + log_b(N). Quotient rule: log_b(M/N) = log_b(M) − log_b(N). Power rule: log_b(Mⁿ) = n × log_b(M). Change of base: log_b(x) = log_c(x) / log_c(b). These rules allow complex logarithmic expressions to be simplified. For example: log₂(8 × 16) = log₂(8) + log₂(16) = 3 + 4 = 7. This is verified: 2⁷ = 128 = 8 × 16 ✓.
The antilogarithm (antilog) reverses the logarithm: if log_b(x) = y, then the antilog is x = b^y. For common log: antilog₁₀(3) = 10³ = 1000. For natural log: antiln(2) = e² ≈ 7.389. For log₂: antilog₂(4) = 2⁴ = 16. Antilogs were essential in pre-calculator arithmetic — logarithm tables were used for multiplication, and antilog tables converted the result back. The antilog calculator on this page lets you enter any log value and base to find the original number.
pH scale: pH = −log₁₀[H⁺] — each pH unit represents a 10× change in acidity. Decibels: dB = 10×log₁₀(P/P₀) — a 10 dB increase is a 10× power increase. Richter scale: each 1.0 magnitude step represents a ~31.6× energy release increase (10^1.5 ≈ 31.6). Compound interest: time to double at rate r: t = ln(2)/ln(1+r) ≈ 72/r% (the Rule of 72). Information entropy: H = −Σ p×log₂(p) bits per symbol. Algorithm complexity: binary search runs in O(log₂ n) time — why databases can find records in milliseconds.
Logarithms are only defined for positive real numbers (x > 0). log_b(0) is undefined because no finite power of b equals zero — as the exponent approaches −∞, b^n approaches 0 but never reaches it. log_b(x) for x < 0 is undefined in real numbers because real exponentiation of a positive base always gives a positive result. In complex mathematics, logarithms of negative numbers exist but involve imaginary components: ln(−1) = iπ (Euler's identity), which is beyond the scope of this calculator. Always ensure x > 0 and b > 0, b ≠ 1.