FormulaCraft

MOD

MOD gives the remainder of a division. It is commonly used to flag every Nth row, alternate shading, or test whether a number is even or odd.

Excel
=MOD(A2, 2)
Google Sheets
=MOD(A2, 2)

Try it with your data

Edit the grid or formula, then run it through a real spreadsheet engine — no signup.

Sample data — click any cell to edit

Runs server-side · free · no signup

How it works

  1. 1A2 is the number, 2 is the divisor.
  2. 2The result is the remainder — 0 means A2 is even.
  3. 3Use =MOD(ROW(), 3)=0 to flag every third row.

Need a version for your data?

Try: “Check whether the number in A2 is even using MOD

Related

Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.

Last reviewed: