# IF: return a result based on a condition

IF lets you describe a simple decision: test a condition, then choose a result for true or false.

## Syntax

`=IF(logical_test, value_if_true, value_if_false)`

## A simple example

`=IF(B2>=10,"In stock","Reorder")`

When B2 contains 8, the formula returns Reorder. When B2 contains 10, it returns In stock because >= includes equality.

## What to watch for

Text results need quotation marks. The order of the last two arguments matters: true first, false second. Use parentheses carefully when nesting functions.

## Build confidence with practice

Try the guided exercise in Sheetstep, then change a number in the practice workbook and observe the result. Use the skills quiz to check what you remember.
