Grade bands with IFS

Decisions with IF · About 5 minutes

Grade bands with IFS

IFS checks conditions in order and shows the result of the first one that is TRUE. It takes pairs: a condition, then its result.

=IFS(B2>=90,"A",B2>=80,"B",B2>=70,"C",B2<70,"D") reads as "90 or more is A, else 80 or more is B, else 70 or more is C, else D". It does the same job as IF inside IF inside IF, but it's easier to read.

Order matters. Start with the highest band, because the first TRUE wins. If no condition is TRUE, IFS shows #N/A, so end with TRUE and a result for everything else.

Part of Plus

Free during our founding launch: sign in to unlock this lesson's exercises, the timed practice sets and the rest of Plus. The free lessons stay free, with no account needed.

What IFS does

IFS checks a list of tests in order and shows the result of the first one that is TRUE. You write pairs: a test, then what to show when it passes.

It does the same job as IF inside IF inside IF, with no nesting. Each band sits side by side in one formula, with one closing bracket at the end, so it is easier to read and to change.

How to write IFS

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

logical_test1
The first test, like B2<=1. Put the band that should win first.
value_if_true1
What to show when that test is TRUE.
logical_test2, value_if_true2, ...
More pairs, checked in order. Excel accepts up to 127 tests. End with TRUE and a result to catch everything else.

IFS worked example

Parcels are sized by weight: up to 1 kg is Small, up to 5 kg Medium, up to 20 kg Large, and heavier is Freight. In C2 to C5, give each size.

Parcels are sized by weight: up to 1 kg is Small, up to 5 kg Medium, up to 20 kg Large, and heavier is Freight. In C2 to C5, give each size.
ABC
1ParcelKgSize
2P-010.8Small
3P-023.5Medium
4P-0312Large
5P-0426Freight
C2=IFS(B2<=1,"Small",B2<=5,"Medium",B2<=20,"Large",TRUE,"Freight")If B2 is 1 or less show Small, else if 5 or less Medium, else if 20 or less Large, else Freight. That gives Small, Medium, Large and Freight.

Common IFS mistakes

Some rows show #N/A

No test was TRUE for those rows. Add TRUE and a result as the last pair, like TRUE,"Freight", so every value gets an answer.

Every parcel gets the same size

Check the order. If B2<=20 comes first, 0.8 kg stops there and shows Large. Put the narrowest band first.

The cell shows #NAME?

That version doesn't have IFS. Excel 2016 and earlier don't, so use a nested IF there.

IFS or nested IF?

Use IFS when you have three or more bands and everyone who opens the file has Excel 2019 or later, Microsoft 365, or Google Sheets. It is shorter and the brackets can't get tangled.

Use a nested IF when the file must work in older Excel. Both stop at the first TRUE test, so the order of the bands matters in both.

Questions people ask

How does the IFS function work?

It takes pairs of a condition and a result, and shows the result of the first condition that is TRUE: =IFS(B2>=90,"A",B2>=80,"B",TRUE,"C").

IFS vs nested IF: which should I use?

They give the same answers. IFS is easier to read with three or more bands; nested IF works in every version, including Excel 2016.

Why does IFS show #N/A?

No condition was TRUE. End with TRUE and a result for everything else.

Why does every score get the top grade?

The bands are in the wrong order. Start with the highest, because the first TRUE wins.

Theme