What it does
IFERROR returns a fallback value when a formula returns an error.
Syntax or pattern
=IFERROR(value, value_if_error)5 practical examples
Hide lookup errors
Return a friendly message when VLOOKUP fails.
=IFERROR(VLOOKUP(A2,Products,3,FALSE),"Not found")This is cleaner than #N/A in report outputs.
Avoid division errors
Return blank when a denominator is zero or missing.
=IFERROR(B2/C2,"")Use this for ratios and percentages.
Show zero for missing values
Return 0 when a calculation fails.
=IFERROR(SUM(D2:F2)/G2,0)Only use zero if it truly means zero in your report.
Clean imported numbers
Convert text to values and return blank if conversion fails.
=IFERROR(VALUE(A2),"")Useful for messy imported data.
Protect nested formulas
Wrap a complex calculation with a readable fallback.
=IFERROR(INDEX(Prices,MATCH(A2,Products,0)),"Check product")The message tells the user what to fix.
Common mistakes to avoid
- Using IFERROR to hide real problems.
- Returning zero when blank would be more accurate.
- Wrapping everything without checking why errors occur.
Related Excel examples
FAQ
Is IFERROR bad practice?
No, but it should not hide important data-quality problems.
Here are some ideas for you
Optional resources that may help if you are learning formulas, building reports, or working in spreadsheets often.
- Excel formula booksSee ideas
Practice formulas with structured examples you can keep beside your desk.
- Excel shortcut guidesSee ideas
Build speed with keyboard shortcuts for selection, formatting and navigation.
- Numeric keypadsSee ideas
Helpful if you enter many numbers on a laptop or compact keyboard.
- External monitorsSee ideas
Useful for viewing large worksheets, formulas and reference tables side by side.
- Desk notebooksSee ideas
Sketch formula logic, report ideas and table structures before building.
- Laptop standsSee ideas
Make long spreadsheet sessions more comfortable and ergonomic.
Some links in this section may be affiliate links. Choose only what is useful for your own work.