IF evaluates the logical_test first. If the result is TRUE it immediately returns value_if_true and ignores value_if_false completely — the false branch is never even calculated. If the result is FALSE it skips value_if_true entirely and returns value_if_false. One behaviour that catches people out: IF treats zero as FALSE and any non-zero number as TRUE. This means =IF(A1,"Yes","No") returns Yes whenever A1 contains any non-zero number, and No when A1 is zero, blank, or FALSE. You can nest one IF inside another by placing the second IF in the value_if_false position of the first — this gives you three possible outcomes. Add a third nesting for four outcomes. Beyond two or three levels of nesting, the formula becomes very hard to read and maintain. That is when
IFS becomes the better choice — it accepts up to 127 condition-result pairs in a flat list with no nesting at all. For multi-condition single tests, combine AND or OR inside the logical_test argument rather than nesting additional IFs.