Math & Trig

LOG Function in Excel

Returns the logarithm of a number to a specified base.

Syntax

  • =LOG(number, [base])

Arguments

  • number (required): Positive number to find log of
  • base (optional): Base of the logarithm (default 10)

Examples

  • =LOG(100) - Log base 10 of 100 - Result: 2
  • =LOG(8, 2) - Log base 2 of 8 - Result: 3

Excel LOG function documentation

  • LOG returns the logarithm of a number to a specified base.
  • Syntax: =LOG(number, [base]). Default base 10; omit base for common log.
  • Use in scientific, financial (log scales), and growth rate transforms.
  • Related: [LN](/functions/ln/), [LOG10](/functions/log10/), [EXP](/functions/exp/).

LOG syntax and valid inputs

  • number must be positive — zero or negative → #NUM!.
  • base optional default 10; must be positive and not 1.
  • LN is natural log base e; LOG10 is base 10 explicitly.
  • Log scale charts often use LOG on axis data in analysis sheets.

Step-by-step: orders of magnitude column

  • Step 1 — Revenue values in A2:A100 spanning wide range.
  • Step 2 — =LOG(A2) for log10 scale.
  • Step 3 — Chart log column for readable spread.
  • Step 4 — Inverse: =POWER(10, log_value) to reconstruct.
  • Step 5 — Growth: =LOG(A2/A1) for log return between periods.

LOG vs LN vs LOG10

  • LOG(n) — base 10 default.
  • LOG(n,2) — base 2 binary log.
  • LN — natural log base e.
  • LOG10 — explicit base 10 alias.

Worked examples to copy

  • Log10: =LOG(1000).
  • Base 2: =LOG(8, 2).
  • Natural via LN: =LN(A2).
  • Log return: =LN(A2/A1).

People also ask

  • LOG of negative? — #NUM!.
  • LOG default base? — 10 in Excel LOG.
  • LOG vs GROWTH function? — GROWTH fits exponential trend; LOG transforms data.
  • LOG Google Sheets? — LOG(value, base) supported.

Common errors

  • #NUM! if number is zero or negative
  • #DIV/0! if base is 1

Use cases

  • Scale conversions
  • Decibel calculations
  • Data normalization

Frequently asked questions

  • How do I use LOG for binary (base 2) calculations? Use =LOG(number, 2) for base-2 logarithms. This is useful in computing: LOG(1024, 2) = 10 (2^10 = 1024). To find how many bits needed to represent a number: =CEILING(LOG(number, 2), 1).
  • How do I calculate decibels using LOG? Decibels use base-10 logarithms. For power ratio: =10*LOG10(P2/P1). For voltage/amplitude ratio: =20*LOG10(V2/V1). Example: a 100x power increase is =10*LOG10(100) = 20 dB.
  • What happens if I omit the base argument in LOG? If you omit the base, LOG defaults to base 10, making it identical to LOG10. So =LOG(100) and =LOG10(100) both return 2. Always specify the base explicitly if you need something other than base 10.

Editorial review

  • Reviewed by Excel.Directory Editorial Team. Updated May 2026.

When to use LOG

  • Scale conversions — common Math & Trig scenario for LOG.
  • Decibel calculations — common Math & Trig scenario for LOG.
  • Data normalization — common Math & Trig scenario for LOG.

LOG in the Math & Trig category

  • Browse all Math & Trig functions at /categories/math-trig/ for related formulas.
  • LOG syntax: =LOG(number, [base])
  • number (required): Positive number to find log of
  • base (optional): Base of the logarithm (default 10)
  • Confirm LOG arguments match the syntax shown above before filling down.
  • Lock table and range references with $ when copying formulas across rows or sheets.

Formula checklist before you copy down

  • Confirm LOG arguments match the syntax shown above before filling down.
  • Lock table and range references with $ when copying formulas across rows or sheets.
  • If results look wrong, check for text stored as numbers and invisible spaces with TRIM.
  • Spot-check three known input rows manually against expected output.

Related Excel functions

  • LN (/functions/ln/): Returns the natural logarithm (base e) of a number.
  • LOG10 (/functions/log10/): Returns the base-10 logarithm of a number.
  • EXP (/functions/exp/): Returns e raised to the power of a given number.

Errors to watch for

  • #NUM! if number is zero or negative — review causes on linked error pages in the directory.
  • #DIV/0! if base is 1 — review causes on linked error pages in the directory.

Copy-paste audit workflow

  • Enter LOG on three test rows with known expected output documented on a QA tab.
  • Fill down only after absolute references are locked on lookup tables and rate tables.
  • Compare against manual calculation or a calculator for financial and statistical functions.
  • Search this directory for comparison guides when choosing between similar functions in the same category.

LOG worked examples to copy

  • =LOG(100) — Log base 10 of 100. Expected result: 2.
  • =LOG(8, 2) — Log base 2 of 8. Expected result: 3.

LOG reference summary for crawlers and offline review

  • LOG belongs to the Math & Trig category in Excel. Returns the logarithm of a number to a specified base.
  • Full syntax: =LOG(number, [base]). Open /functions/log/ for parameters, FAQs, and related pages.
  • Common mistakes: #NUM! if number is zero or negative; #DIV/0! if base is 1
  • Pair this function with comparison guides when another Excel formula might fit the same task better.
  • Review fix-excel-formula-errors when unexpected errors appear after upgrading Excel or sharing across locales.