IF With Multiple Conditions in Google Sheets

By Tomosuke Hasegawa · Updated Oct 29, 2026 · Beginner to intermediate · 6 min read · includes 2 free exercises

In short: Put AND or OR inside the test of an IF. =IF(AND(test1, test2), "yes", "no") needs every test to be true. =IF(OR(test1, test2), "yes", "no") needs at least one.

IF takes one test, so combine them

The first argument of IF is a single TRUE or FALSE. To check several conditions, wrap them in AND or OR, which each return a single TRUE or FALSE, and use that as the test.

The example

Here are four students in cells A1:C5, with a test score and an attendance percentage.

ABC
1NameScoreAttendance
2Ann8295
3Ben5490
4Cara6770
5Dev9185

AND: every condition must be true

Per Google's help page, AND returns TRUE only if all of its arguments are true. To pass a student only if the score is at least 60 and attendance is at least 90:

=IF(AND(B2>=60, C2>=90), "Pass", "Fail")

For Ann (82 and 95) this returns Pass. Here is why:

  1. B2>=60 is TRUE and C2>=90 is TRUE.
  2. AND returns TRUE because both are true, so IF returns "Pass".

For Cara (67 and 70), attendance fails the second test, so AND is FALSE and the result is Fail.

OR: at least one condition must be true

OR returns TRUE if at least one argument is true. To give an award for a score of 90 or more, or attendance of 95 or more:

=IF(OR(B5>=90, C5>=95), "Award", "")

For Dev (score 91) this returns Award. The empty quotes mean the cell stays blank when neither test passes.

Mixing AND and OR

You can nest them: AND(B2>=60, OR(C2>=90, D2="Excused")). Use brackets carefully and add one test at a time.

Nested IF or IFS?

AND and OR answer "do these conditions hold together?" with one result. When you need different results for different cases, such as grades A, B and C, use a nested IF or the IFS function.

Common mistakes

Try it yourself

Use the table above (A1:C5). Type your formula into the box, starting with =, then press Check.

Exercise 1: Both must pass

For Ann's row, write an IF that returns Pass only when the score in B2 is at least 60 and the attendance in C2 is at least 90, and Fail otherwise.

Hint: put both tests inside AND.

Exercise 2: Either one

For Dev's row, write an IF that returns Award when the score in B5 is at least 90 or the attendance in C5 is at least 95, and stays blank otherwise.

Hint: the false result is empty quotes.

What to learn next

Syntax and rules in this guide were checked against Google's IF with multiple conditions help page. See all guides.