How to Use OR Function in Google Sheets (with Examples)

OR function is useful when you want to evaluate a set of conditions.

It will return TRUE when any of the conditions being checked are met, else it returns FALSE.

OR Function Syntax

OR(logical_expression1,¬†[logical_expression2, …])

  • logical_expression1 – The first condition that you want to check. This could be a cell reference that has the TRUE/FALSE value or an expression that returns logical values.
  • [logical_expression2].. – Additional conditions that you want to check.

Additional Notes:

  • OR function can be used with other formulas to be more efficient. For example, if you’re testing two conditions and your final result is ‘Pass’ if any of the two conditions is met. You can use a formula such as =IF(OR(A1=”Pass”,A2=”Pass”),”Pass”,”Fail”).
  • The arguments must either evaluate to logical values (TRUE/FALSE), or the arguments must be arrays/references of logical values.
  • Text and empty cells are ignored.
  • If the specified range contains no logical values, the OR function returns #VALUE! error.

OR Function in Google Sheets – Examples

Now let’s look at some examples where you can use the OR function in Google Sheets.

Example 1 – Test Multiple Conditions Using OR Function

Suppose you have a dataset as shown below and you want to find it any of the tests passed. If any of the tests pass, the formula should return PASS, else it should return FAIL.

Testing Multiple Conditions in OR Functions in Google Sheets

The below formula can do this:


Note that this is an array formula as we are testing multiple cells at one go. You don’t need to write this formula this way. You can simply write the formula¬†=OR(B2:B4=“Pass”) and then use Control + Shift + Enter instead of just using Enter.

In the above formula, OR function evaluates the cells and returns TRUE if any of the tests is a ‘pass’, else it returns a false. If function then uses this result to return “Pass” or “Fail”.

Example 2 – Check Whether a Date is a Weekend Day Or Not

Suppose you have a dataset as shown below:

OR Function in Google Sheets - Checking for Weekend Day

You can use the OR function along with the WEEKDAY function to check if the day is a weekend or not.

Below formula would return TRUE if it’s a weekend day, else it will return FALSE.


In this formula, the weekday function returns 6 for a ‘Saturday’ and 7 for a ‘Sunday’. OR function then returns TRUE when the result of WEEKDAY function is 6 or 7.

Example 3 – Using Nested OR function

Suppose you have a dataset as shown below:

Nested OR Function in Google Sheets

In the above case, access is granted only if you are from either Marketing or Sales department or you have the A grade classification.

The below formula will give TRUE if access is to be granted and FALSE if the conditions are not met and access is not to be granted.


Nested OR Function in Google Sheets - results

Note that this is a case of nested OR functions where one OR function is used with in the other.

Related Google Sheets Functions:

Spreadsheet Expert at Productivity Spot | Website | + posts

Google Sheets and Microsoft Excel Expert.