IFS Function

Checks several conditions in order and returns the result for the first one that's TRUE.

Category

Logical

Available in

Excel 2019+, Microsoft 365

Returns

The value paired with the first TRUE test

Taught hands-on in Level 3: Intermediate Lookups & Data Summaries - Smarter Logic module

Overview

IFS replaces long chains of nested IFs. You list pairs of “test, result”, and Excel works down the list returning the result for the first test that passes.

It's ideal for grades, commission tiers, shipping bands and anything else with several levels.

Syntax

=IFS(logical_test1, value_if_true1, [logical_test2, value_if_true2], …)

Arguments

ArgumentRequired?What it does
logical_test1YesThe first condition to check.
value_if_true1YesThe result if logical_test1 is TRUE.
logical_test2, value_if_true2, …OptionalMore test/result pairs, up to 127, checked in order.

Examples

Example 1 — Letter grades

90+ is an A, 80+ a B, 70+ a C, everything else an F.

C2fx=IFS(B2>=90, "A", B2>=80, "B", B2>=70, "C", TRUE, "F")
ABC
1StudentScoreGrade
2Ana94A
3Ben81B
4Cara67F
5Dev75C
=IFS(B2>=90, "A", B2>=80, "B", B2>=70, "C", TRUE, "F") Explain
  1. Ben's 81 fails B2>=90 but passes B2>=80, so he gets B — later tests are never checked.
  2. The final TRUE, "F" pair always passes, so it acts as the “everything else” result.

Example 2 — Commission tiers

Pay 3% under 10,000, 5% up to 25,000 and 8% above that.

=B2 * IFS(B2>25000, 8%, B2>=10000, 5%, TRUE, 3%) Explain
IFS can sit inside a bigger formula — here it just picks the rate, and the multiplication happens outside.

Common mistakes

  • #N/A errors. No test was TRUE. Add TRUE, "…" as the last pair to catch everything else.
  • Wrong tier chosen. Tests are checked in order. Put the strictest (highest) threshold first.
  • "You've entered too few arguments". Every test needs a result. Count your pairs.

Notes

  • If you're matching one value against a list of exact options ("N" → North, "S" → South), SWITCH is shorter.
  • Related functions: IF, SWITCH, XLOOKUP (for tiers kept in a table).
Kyle Stott

Author

Kyle Stott

Certified Microsoft Excel Expert

Kyle has worked professionally with Microsoft Excel for over a decade and has consulted on and taught Excel best practices to over 400 companies across 30+ countries.