ExcelUnpackUnpack Excel, one formula at a time.
Log inSign up

Lesson 68 · Numbers and math

MOD: even and odd in Excel

MOD gives the remainder after dividing. =MOD(A2,2) is 0 for even numbers and 1 for odd numbers. It also tells you how many are left over when you split into groups.

Practice this lesson →Pro lesson. The first 4 lessons are free.

What you will learn

  • Find a remainder with MOD
  • Tell if a number is even or odd

How it works

=MOD(A2,2) is 0 for even numbers and 1 for odd numbers.

=IF(MOD(A2,2)=0,"Even","Odd") labels them.

Formulas at a glance

=MOD(A2,2)remainder after ÷ 2
=IF(MOD(A2,2)=0,"Even","Odd")The pattern to follow

Example

Write the formula to find the remainder when the first number is divided by 2.

ABCD
1NumberRemainder ÷ 2Even or oddLeft over in teams of 3
214
37
422
59
630

Click B2 and type =MOD(A2,2), then press Enter.

The answer is 0.

When to use it

  • Even or odd labels
  • People left over after making teams
  • Every 3rd or every 5th row

Common mistakes

  • Mixing up the orderThe number comes first, then what you divide by.
  • Expecting the answer of the divisionMOD gives only what is left over.
  • Testing =1 for evenEven numbers give 0.

Practice it on a real sheet

Reading is a start. Doing it is how it sticks. This lesson walks you through every click on a live spreadsheet and checks each answer.

MOD: even and odd in Excel: how it works, with examples · ExcelUnpack