These docs are for v1.0. Click to read the latest docs for v1.2.

IFERROR

Checks if the expression has an error and, returns a replacement value, if so, or the original value otherwise.

Syntax

=IFERROR(expression, replacement)

Arguments

ArgumentTypeDescription
expressionAnyThe expression to evaluate for errors
replacementAnyThe value to return if the expression evaluation resulted in an error

Examples

=IFERROR(1 + [1, 2, 3], 0)0
Because an error occured during evaluation the value 0 was returned.

=IFERROR(1 + 2, 0)3
Because no error occured during evaluation the resulting value was returned.