GESTEP function

Returns 1 if a number is greater than or equal to a step value, 0 otherwise; ideal for flagging or counting values meeting a threshold.

=GESTEP(number, [step])

Generate a GESTEP formula

Describe what you need. The generator will reach for GESTEP where GESTEP is the right tool, and tell you when it is not.

How to get a better answer
  • Name your columns by letter and by header: "column F (Net Value)" beats "the amount column".
  • State every condition, including the negatives — "not cancelled" changes the formula's shape.
  • Say where the data starts if it is not row 1, and whether it will grow.
  • Check the settings above match your spreadsheet: the wrong argument separator is a syntax error on your machine.

Arguments

How GESTEP reads its arguments
numberrequiredstepoptionalGESTEP
ArgumentRequiredDescription
numberRequiredThe numeric value to test (required). Can be a cell reference, literal, or formula result. Non-numeric values return #VALUE!.
stepOptionalThe threshold to compare against (optional; defaults to 0 if omitted). Must be numeric; text causes #VALUE!.

Returns

A numeric value: 1 (true) or 0 (false).

Availability

Excel: All · Google Sheets: Supported

Worked examples

1. Check if a score qualifies for honors

StudentSubjectScore
AliceMath92
=GESTEP(92,90)

Result: 1

Alice's Math score of 92 is greater than or equal to the honors threshold of 90, so GESTEP returns 1. This indicates the score qualifies.

2. Identify scores below the passing threshold

StudentSubjectScore
DavidMath68
=GESTEP(68,70)

Result: 0

David's Math score of 68 is less than 70, so GESTEP returns 0. This shows the score does not meet the passing threshold.

3. Count how many scores meet a passing standard

StudentSubjectScore
AliceMath92
AliceScience78
BobMath85
CarolEnglish95
DavidMath68
=SUMPRODUCT(GESTEP(D2:D6,70))

Result: 4

GESTEP returns 1 for each score >= 70 and 0 otherwise. SUMPRODUCT sums these results: 92, 78, 85, and 95 all qualify (4 scores), while 68 does not.

Common errors

Which GESTEP error are you seeing?
GESTEP returned an error#VALUE!
Ensure the number argument references a column with numeric scores, not text identifiers like student names.
#VALUE!
Use a number for the step parameter, such as =GESTEP(92,90) instead of =GESTEP(92,'excellent').
#VALUE!
Use IFERROR to handle error cells, or ensure source data is clean: =IFERROR(GESTEP(D2,70),0).
ErrorWhy it happensHow to fix it
#VALUE!The number argument is text (e.g., a student name) instead of a numeric value.Ensure the number argument references a column with numeric scores, not text identifiers like student names.
#VALUE!The step argument is text (e.g., 'excellent') rather than a numeric threshold value.Use a number for the step parameter, such as =GESTEP(92,90) instead of =GESTEP(92,'excellent').
#VALUE!A referenced cell contains non-numeric data or a formula error that GESTEP cannot evaluate.Use IFERROR to handle error cells, or ensure source data is clean: =IFERROR(GESTEP(D2,70),0).

Tips and when to use something else

  • GESTEP is ideal for creating 0/1 flags instead of TRUE/FALSE when you need numeric results for calculations or array formulas like SUMPRODUCT.
  • For more complex logic—such as 'A if score ≥ 90, B if ≥ 80, C if ≥ 70'—use IF, IFS, or SWITCH instead of nesting GESTEP calls.
  • Combine GESTEP with SUMPRODUCT to count how many scores in a range meet a threshold: =SUMPRODUCT(GESTEP(range, threshold)) is much faster than row-by-row IF checks.
  • When step is omitted, GESTEP defaults to 0, checking if the number is non-negative (>= 0). This is useful for filtering out negative values.

Frequently asked questions

How is GESTEP different from using a >= comparison?
GESTEP returns a number (1 or 0), while >= returns a boolean (TRUE or FALSE). This matters in array formulas and calculations where you need numeric output. Both check the same >= condition.
What happens if I omit the step argument?
GESTEP defaults step to 0, so =GESTEP(A1) checks if A1 >= 0. This is useful for filtering out negative scores without explicitly specifying a threshold.
How do I count how many students passed (score >= 70)?
Use =SUMPRODUCT(GESTEP(scores_range, 70)). GESTEP converts each score to 1 or 0, and SUMPRODUCT sums them, giving the count of passing scores in one formula.
Should I use GESTEP or IF to check a condition?
Use GESTEP when you only need to flag values as meeting a single threshold and want a 0 or 1 result. Use IF for branching logic, like assigning letter grades (A/B/C/D/F), because GESTEP only checks one condition.

Need a different formula?

The full generator is not scoped to one function — describe any spreadsheet problem and it will pick.

Open the formula generator

Reviewed 2026-09-17