# Logarithm calculator > How do you calculate a logarithm in any base? Find log_b(x) or the power b^y in any base, with ln, log₁₀ and log₂. Calculate the logarithm of a number in base 10, e, 2 or any base, solve b^x = y, and see the change of base and the log curve with your point on it. - Page: https://how.box/logarithm/ - Runs entirely in the browser. - License: HowToolbox's own text and data (titles, explanations, FAQs, tool descriptions and schemas, this file) are CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/); AI training and answers are welcome. Attribute "HowToolbox (how.box)" with a link to the page used. Third-party data keeps its own terms; the name and logo are not licensed. Publisher: HowToolbox, contact@how.box. Terms: https://how.box/about/terms/ ## Inputs Answer link: https://how.box/logarithm/?s={s}&b={b}&cb={cb}&x={x}&y={y} - `s` (exponent or number): What to find: exponent (default) or number. Example: `exponent`. - `b` (10, e, 2 or custom): Base: 2, 10, e or custom. Example: `2`. - `cb` (number 0 to 1e6): The base when b is custom. Example: `3`. - `x` (number 0 to 1e300): x (s exponent). Example: `8`. - `y` (number -1000 to 1000): y (s number). Example: `3`. Example answer: https://how.box/logarithm/?s=exponent&b=2&cb=3&x=8&y=3 A complete link carries the primary answer in the page HTML; a missing or invalid value shows the default page. ## Agent tools - `logarithm_calculate`: y = log_b(x) ⟺ b^y = x. - MCP, one POST to https://how.box/mcp: `{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"logarithm_calculate","arguments":{"solve":"exponent","base":"2","custom_base":3,"number":8,"exponent":3}}}` - GET: https://how.box/mcp/run/logarithm_calculate?solve=exponent&base=2&custom_base=3&number=8&exponent=3 ## How it works A logarithm answers the question: to what power must I raise the base to get this number? Since 10³ = 1000, log₁₀(1000) = 3, and since 2⁵ = 32, log₂(32) = 5. So y = log_b(x) and b^y = x say the same thing, and this tool works in both directions. Calculators usually only know ln (base e ≈ 2.71828) and log (base 10). Any other base comes from the change-of-base rule log_b(x) = ln(x) / ln(b). For log₃(81): ln 81 / ln 3 = 4.39445 / 1.09861 = 4, because 3⁴ = 81. The curve always passes through (1, 0) and (b, 1), climbs ever more slowly for bases above 1, and never reaches x = 0. Logarithms exist only for positive numbers and bases other than 1. Results are rounded to six significant digits. Sources: OpenStax College Algebra 2e, sections 6.3 and 6.5. ## FAQ **What is the difference between log and ln?** ln means base e, while log often means base 10. Some subjects use log for other bases, so check the convention and select the intended base. **How do I solve 2^x = 50?** Choose Logarithm, base 2 and number 50. The result is x ≈ 5.64386. **Why can a logarithm be negative?** For a base greater than 1, numbers between 0 and 1 have negative logarithms. A negative exponent gives the reciprocal of a positive power. **Can I use a base between 0 and 1?** Yes. Choose a custom base; the logarithm then decreases as the input increases. **Is log(x + y) equal to log(x) + log(y)?** No. The sum of logarithms equals the logarithm of a product, log(xy), for positive x and y in the same base. More: [HowToolbox index](https://how.box/llms.txt) · [Agent Skill](https://how.box/skill.md) · [agent terms](https://how.box/about/agents/)