FormulaCamp
Completed
← All functions
Logic

IFS

Returns the result for the first condition that is true.

Syntax

IFS(logical_test1, value_if_true1, …)

Example: =IFS(B2>=90,5,B2>=75,4,TRUE,3)

Available in: Excel 2019+

IFS checks several conditions in order and returns the value for the first one that is true, with no nesting: =IFS(test1, value1, test2, value2, …). It is available in Excel 2019 and Microsoft 365.

When to use it

Arguments explained

Worked examples

Letter grade

A
1Score
284

Formula: C1: =IFS(A2>=90,"A",A2>=80,"B",A2>=70,"C",TRUE,"F")

Result: B

Tests run in order; 84 fails the first test and passes the second. The final TRUE acts as an "everything else" catch-all.

Shipping cost by weight

A
1Weight (lb)
23

Formula: C1: =IFS(A2<=1,4.5,A2<=5,7.9,TRUE,12.5)

Result: 7.9

Up to 1 lb costs 4.50, up to 5 lb costs 7.90, anything heavier 12.50.

No condition matches

A
1Value
250

Formula: C1: =IFS(A2>100,"High")

Result: #N/A

With no matching test and no TRUE fallback, IFS returns #N/A.

Try it

A tiny spreadsheet with example data. Edit the formula or any number and see the result.

Formula in F2: =IFS(B2>=90,"A",B2>=75,"B",TRUE,"C")

Example spreadsheet for IFS
ABCDEF
1StudentScoreExtra creditAttemptsResult
2Ann92Yes2A
3Bob74No0
4Cy58Yes3
5Dee81No1
6Eli662
Result in F2: A
Practice this in a lesson: Nested IF and IFS

Common errors and how to fix them

Related functions

Frequently asked questions

What is the difference between IF and IFS?
IF handles one test with two outcomes and needs nesting for more. IFS takes any number of test and value pairs in one flat list.
How do I add an else case to IFS?
End with TRUE and the default value, for example TRUE,"Other".
Does IFS evaluate all conditions?
It returns the first true one, so later results are ignored.
Can IFS replace a lookup table?
For a handful of bands yes; for many bands a lookup table with approximate-match VLOOKUP or XLOOKUP is easier to maintain.

More in Logic