Evaluate a logarithm of any base using the change of base formula, or solve a logarithmic equation for x.
Enter a base and x to evaluate the logarithm
Enter a base and y to find x
This logarithm calculator is a free tool for evaluating log_b(x) — a logarithm of any positive base — using the change of base formula, or for solving a logarithmic equation log_b(x) = y for the unknown x. A logarithm answers the question "what power must the base be raised to, to produce this number?" It is the inverse operation of exponentiation, so every log calculation on this page is checked against, and can be verified by, the matching exponential calculation. Whether you need a log calculator for algebra homework, a natural log calculator (ln) for calculus, or a quick log base 2 calculator for computer science, this tool shows the formula and full working behind every result.
The calculator has two linked tools. Evaluate log_b(x) takes a base b and an argument x and returns y, the exponent that makes b^y = x, using the universal change of base formula log_b(x) = ln(x) ÷ ln(b). It also displays the natural log, log base 10, and log base 2 of x for quick cross-reference. Solve for x in log_b(x) = y runs the operation in reverse: given a base and an exponent, it rewrites the equation in exponential form and computes x = b^y directly.
Algebra and precalculus students working through logarithm and exponential equation homework, computer science students analyzing algorithm time complexity, chemistry and biology students computing pH or population growth, audio and signal engineers converting to decibel scales, finance students solving for compounding periods, and anyone who needs a fast, verifiable log base b calculator without deriving the change of base formula by hand.
Logarithms compress enormous ranges of numbers into small, comparable scales. A number as large as a billion and one as small as a millionth can both be represented with a modest logarithm value, which is why logarithmic scales appear throughout science and engineering — pH, decibels, earthquake magnitude, and star brightness are all logarithmic. Logarithms are also the standard tool for solving equations where the unknown sits in an exponent, such as "how many years until this investment doubles?"
Chemists use −log₁₀[H⁺] to compute pH. Audio engineers use 10·log₁₀(I/I₀) to express sound intensity in decibels. Seismologists report earthquake magnitude on the logarithmic Richter scale. Computer scientists use log₂ n to describe the time complexity of binary search and balanced trees. Financial analysts solve logarithmic equations to find the number of compounding periods needed to reach a savings goal. Biologists use logarithmic and exponential models to describe population growth or radioactive decay.
The change of base formula, the three log rules, and the exponential form used to solve for x
log_b(x) = y is exactly the same statement as bʸ = x. This calculator's two tools verify each other by moving between these two forms.
ln(x) is log base e. Every other base is computed from it via change of base: log_b(x) = ln(x) ÷ ln(b), so only one internal log function is ever needed.
The base must be positive and not 1; the argument x must be strictly positive. Violating either makes the logarithm undefined in the real numbers.
From picking a tool to verifying the answer
Choose Evaluate log_b(x) to compute a logarithm, or Solve for x in log_b(x) = y to work backward from a known exponent.
Type a base that is positive and not equal to 1 — common choices are 2, 10, or e (≈2.71828), but any valid positive base works.
For Evaluate, enter the argument x (must be greater than 0). For Solve for x, enter the exponent y — any real number, including negatives or decimals.
The calculator applies the change of base formula, or rewrites the equation in exponential form, and displays the result instantly.
Evaluate mode also shows ln(x), log base 10 of x, and log base 2 of x side by side, so you can compare the same number across common bases.
Switch tools and rewrite your equation in the other form — x = bʸ — to confirm both tools agree on the same numbers.
Evaluate log₂(8), then verify it with the Solve for x tool
What power must 2 be raised to, to get 8? We'll evaluate log₂(8) using the change of base formula, then confirm the answer by solving log₂(x) = 3 for x.
Explanation: Because 2³ = 8, log base 2 of 8 must equal exactly 3 — and the change of base formula, using natural logs, arrives at the same answer through division rather than trial and error. This is the entire value of the change of base formula: it lets a calculator compute a logarithm of any base using only a single natural-log function, then the Solve for x tool proves the result is correct by rebuilding 8 from 2³.
What each field in the result actually represents
| Field | What It Means | Example Reading |
|---|---|---|
| log_b(x) result (y) | The exponent that base b must be raised to, to produce x | log₂(8) = 3 → 2 must be cubed to reach 8 |
| ln(x), log₁₀(x), log₂(x) reference values | The same x evaluated in three common bases, for quick comparison | x=8 → ln≈2.0794, log₁₀≈0.9031, log₂=3 |
| x (Solve for x tool) | The value produced when base b is raised to exponent y | log₂(x)=3 → x=8 |
| Undefined / rejected inputs | Base ≤ 0, base = 1, or x ≤ 0 — outside the domain of real logarithms | base=1 or x=−5 is blocked with an error message |
Typical ranges: log_b(x) is negative whenever 0 < x < 1 (for a base greater than 1), zero when x = 1, and positive when x > 1. There's no upper or lower bound — logarithms can be arbitrarily large or small as x grows or shrinks.
Manual verification: the fastest sanity check for any log_b(x) = y result is to compute b^y by hand or with the Solve for x tool — it should return your original x exactly (aside from tiny floating-point rounding).
Where logarithm calculations show up across school, science, and industry
Evaluate logarithms and solve logarithmic equations step by step, in any base.
Check change-of-base formula calculations for a base your calculator doesn't support directly.
Compute pH from hydrogen ion concentration using the log base 10 formula.
Understand Richter scale readings, which are logarithmic measures of seismic energy.
Convert sound intensity ratios into the logarithmic decibel scale.
Analyze O(log n) time complexity for binary search, balanced trees, and divide-and-conquer algorithms.
Use log base 2 to estimate tree depth or the number of bits needed to represent n values.
Solve for the number of periods needed for an investment to reach a target value at a given growth rate.
Analyze population growth or radioactive decay using logarithmic and exponential relationships.
Apply logarithmic transforms to normalize skewed data before statistical modeling.
Practice logarithm and exponential equation questions common on algebra and college entrance exams.
Work with logarithmic frequency and gain scales in filter and system design.
Use logarithms to solve for elapsed time given a decay constant and remaining quantity.
What this logarithm calculator does well, and where manual judgment is still needed
Three logarithm bases you'll encounter constantly, side by side
| Name | Base | Common Notation | Typical Use |
|---|---|---|---|
| Common Logarithm | 10 | log(x) or log₁₀(x) | pH, decibels, Richter scale, orders of magnitude |
| Natural Logarithm | e ≈ 2.71828 | ln(x) | Calculus, continuous growth/decay, compound interest |
| Binary Logarithm | 2 | log₂(x) or lb(x) | Computer science, information theory, algorithm complexity |
Summary: This logarithm calculator gives you an instant, free way to evaluate log_b(x) for any valid base, with natural log, log base 10, and log base 2 reference values, and to solve logarithmic equations for x — all with the formula and steps shown. Pair it with the Exponent Calculator and Scientific Notation Calculator for a fuller picture of exponential math.
Common questions about logarithms
Trusted educational references to go deeper on the math behind logarithms
Explore other math tools