Fix #DIV/0! Error in Excel

This error occurs when a formula tries to divide a number by zero or an empty cell.

Why this happens

  • Dividing by zero explicitly
  • Dividing by an empty cell
  • Average of empty range

How to fix it

  • Use IF to check for zero before dividing
  • Use IFERROR to handle the error
  • Ensure divisor cells have values

High-impact #DIV/0! checks

  • Check whether the denominator is zero, blank, or produced by another formula returning zero.
  • Use IF or IFERROR to show a friendly result only after confirming the division is expected.

#DIV/0! handling

  • Guard with IF: =IF(denominator=0,"",numerator/denominator).
  • Use IFERROR only after validating business logic.
  • Check for blank cells used as divisors in SUMPRODUCT ratios.

Functions that often show this error

  • AVERAGE: Returns the average (arithmetic mean) of the arguments.
  • MOD: Returns the remainder after a number is divided by a divisor.
  • AVERAGEIF: Returns the average of cells that meet a single criterion.
  • LOG: Returns the logarithm of a number to a specified base.
  • AVERAGEIFS: Returns the average of cells that meet multiple criteria.
  • CORREL: Returns the correlation coefficient between two data sets.
  • ATAN2: Returns the arctangent from x and y coordinates.
  • QUOTIENT: Returns the integer portion of a division.
  • COT: Returns the cotangent of an angle in radians.
  • COTH: Returns the hyperbolic cotangent of a number.
  • SEC: Returns the secant of an angle in radians.
  • CSC: Returns the cosecant of an angle in radians.
  • CSCH: Returns the hyperbolic cosecant of a number.
  • PERCENTOF: Calculates the percentage that a subset represents of a total.
  • FORECAST: Calculates a future value based on existing values using linear regression.