Google Sheets NA Function: Show Missing Data
In this article
The NA function in Google Sheets fills a cell with the #N/A error on purpose. You use it when a value genuinely does not exist or has not been found yet, and you want that gap to be obvious instead of hidden as a zero or a blank. The entire formula is =NA() — it takes no arguments and returns the error value #N/A. Everything else in this guide is about when to use it, how to pair it with functions like IFERROR and VLOOKUP, and how to keep it from breaking charts and totals.
What You'll Need
- A Google Sheets account and a spreadsheet you can edit (the function is available on desktop and mobile browsers, and in the mobile apps).
- At least one cell where a value may be unknown or not yet matched — for example a lookup column, or a placeholder row in a data table.
- Basic familiarity with typing formulas that begin with an equals sign.
Step-by-Step
- Pick the cell. Click the cell where the missing value should appear. This is often a whole column of results below a lookup formula, where some rows have a match and some do not.
- Type the function. Click into the formula bar (or start typing directly in the cell) and enter
=NA(). Note the empty parentheses — there are no arguments, and adding anything inside them produces an error. - Press Enter. The cell now displays
#N/A. The text in the formula bar still reads=NA(), so anyone clicking the cell can see it was deliberate rather than a broken formula. - Use it inside a condition (optional). A more useful pattern is to return NA only when a condition is true. For example,
=IF(A2="", NA(), A2*2)returns #N/A whenever A2 is empty, and the doubled value otherwise. This stops blanks from silently producing misleading zeros. - Combine it with IFERROR or IFNA (optional). Because #N/A is a real error value,
IFERRORwill catch it. If you want to swap your deliberate #N/A for a message, write=IFERROR(NA(),"Value not recorded"). To catch only #N/A and let other errors through, useIFNAinstead. - Apply it to a lookup (optional). When a VLOOKUP or XLOOKUP cannot find a match, it already returns #N/A. If you want to be explicit, wrap the lookup so a missing result is forced to #N/A:
=IF(B2="",NA(),VLOOKUP(B2,$D$2:$E$50,2,FALSE)). This makes the missing product code visible before the lookup runs. - Check how your totals react. Functions such as SUM, AVERAGE and COUNT ignore error values in ranges, but a chart series containing #N/A may show gaps. Test one chart or summary row after adding the function so you know what your downstream formulas will do.
- Verify the result. Click the cell and confirm the formula bar shows
=NA(). If it shows #NAME? instead, the function was typed incorrectly — usually a missing parenthesis or a stray argument.
Labels and menu names can differ slightly between Google Sheets versions, devices and regions; the formula text itself is the same everywhere.
Common Mistakes
- Typing an argument.
=NA(1)or=NA("missing")is invalid. The function accepts nothing between the parentheses. - Confusing NA with a text string. Typing the letters NA without the equals sign and parentheses creates plain text that looks similar but is not an error value, so IFERROR, ISNA and charts will not treat it as one.
- Using it to hide a real problem. Hard-coding #N/A over a broken lookup formula hides the root cause. Fix the lookup first, then decide whether a missing value should be flagged.
- Expecting it inside a quote.
=NA()returns an error;="NA()"returns the four-character text NA(). Only the unquoted version behaves like the error value. - Forgetting the cascade. Any cell that references a #N/A cell generally inherits the error, so one placeholder can turn a whole column red. That is often the point, but plan for it.
Tips
- Use
ISNA(cell)to test whether a cell currently holds #N/A, which is handy in a helper column that counts or flags missing entries. - If you want a blank instead of an error but still want to notice the gap, use
IFERROR(NA(),"")and apply conditional formatting to highlight empty cells. - Keep a comment on the cell explaining why #N/A is deliberate, so a colleague does not "fix" it by deleting your formula.
- For dashboards, consider displaying #N/A while data is pending but replacing it with a clear label once the source is final.
- Use Ctrl+Z (Cmd+Z on Mac) immediately if you overwrite a formula with the function by mistake.
Troubleshooting
The cell shows #NAME? instead of #N/A. The function was misspelled or the parentheses are unmatched. Retype it as =NA() with no space inside the parentheses.
The cell shows the text "NA()" instead of an error. You probably typed a leading apostrophe or wrapped the whole thing in quotes. Remove the apostrophe or the surrounding quotes.
My totals show errors after adding it. SUM and similar functions ignore errors in referenced ranges, but a direct reference like =B2+10 will return #N/A if B2 is #N/A. Replace direct arithmetic with an aggregate function or wrap the reference in IFERROR where a fallback makes sense.
My chart broke. Error values can create gaps or drop points. Either filter the placeholder rows out of the chart range or replace #N/A with a label during chart building.
A lookup still returns #N/A even when the value exists. This is not the NA function's fault — check for trailing spaces, text versus number formatting, or a lookup range that is not locked with dollar signs before dragging the formula down.
If that did not work, select the cell and look at the formula bar rather than the displayed value, then rebuild the formula from scratch in an empty cell to isolate the problem.
Frequently Asked Questions
Does the NA function take any arguments?
No. It is entered as =NA() with empty parentheses. Any argument inside them causes an error.
What is the difference between #N/A and other errors?
#N/A specifically means a value is not available. Other errors such as #DIV/0! or #VALUE! signal a calculation problem. IFNA catches only #N/A, while IFERROR catches all error types.
Why would I return #N/A on purpose?
It makes missing data visible. A zero or a blank can be mistaken for a real value, whereas #N/A clearly says "nothing was found here," which is useful in lookup columns and audits.
Can I use NA inside IFERROR?
Yes. Because #N/A is an error value, =IFERROR(NA(),"fallback") returns the fallback text. Use IFNA if you only want to replace #N/A.
Will SUM ignore cells containing #N/A?
SUM over a range ignores error values rather than returning an error itself, but direct arithmetic that references a #N/A cell propagates the error. Test your specific formula.
Does NA work the same in Excel?
Yes, the function behaves the same in Excel and Google Sheets: it takes no arguments and returns #N/A.