Excel Not Blank Symbol: What <> Means

How-to basics · Updated November 18, 2026

In Excel, the not-blank test usually uses the not-equal operator <> with an empty string: =A2<>"". If A2 contains a value, the formula returns TRUE; if it is empty, it returns FALSE. The operator is two angle brackets, not the single symbol ≠, and the empty quotation marks tell Excel what the cell is being compared with.

What the not-blank symbol means

Excel does not have a dedicated “not blank” character. Instead, <> is its comparison operator for “not equal to.” It can compare numbers, text, dates, or other values. Pairing it with "" asks whether a cell’s value differs from an empty text string, which is a handy test for whether the cell appears to contain something.

For example, with a name in A2, =A2<>"" returns TRUE for a name and FALSE for an empty cell. The double quotation marks are important: they represent an empty string, not a space. Typing <> by itself is not a complete comparison in a normal worksheet formula, because Excel still needs a value or expression to compare against.

The English phrase “not blank” can mean two slightly different things: a cell is physically empty, or it does not display content. Those meanings often agree, but formulas that return an empty string and cells containing spaces can make them differ. Choosing the right test depends on what you want your spreadsheet to treat as empty.

Test one cell in a formula

With the value or formula to check in A2, enter =A2<>"" in another cell. Excel returns TRUE when A2 evaluates to something other than an empty string, and FALSE when its value is empty or evaluates to an empty string. This makes the test useful inside a larger formula as well as on its own.

For a label instead of TRUE or FALSE, with the value to check in A2, use =IF(A2<>"","Filled","Blank"). A2 containing 42 returns Filled; an empty A2 returns Blank. The words are just examples, so you can replace them with statuses such as “Ready” and “Missing.”

Excel’s comparison result is a logical value, not text. You can use it in an IF condition, combine it with other tests, or use it to flag rows. For instance, a form tracker could show a follow-up status only after a contact field has been entered. Be aware that a cell containing an error such as #N/A can make the comparison return an error rather than TRUE or FALSE.

Count cells that are not blank

To count nonblank cells in a range, a common option is COUNTIF with the not-equal-to-empty-string criterion. With entries in A2:A20, use =COUNTIF(A2:A20,"<>"). If A2:A20 contains three names, two numbers, and the rest are genuinely empty, the result is 5. A number such as zero is still a value and is counted; a cell containing one or more spaces is also not truly empty to this test.

There is an important wrinkle: a cell can contain a formula that displays nothing. If the exact distinction matters, compare each result to an empty string and add the TRUE results. With possible entries or formulas in A2:A20, use =SUMPRODUCT(--(A2:A20<>"")). If the range contains North, a truly empty cell, a formula returning an empty string, a space, and 0, this returns 3: North, the space, and zero evaluate as nonempty, while the empty cell and empty-string result do not.

That second formula counts based on the values the cells evaluate to, rather than simply asking whether a cell has been used. It is particularly useful in reports where formulas fill a whole column but are designed to show blank results until source data arrives. For a straightforward list of manually entered values, COUNTIF is easier to read and is usually sufficient.

Not blank is different from ISBLANK

ISBLANK asks whether a cell is genuinely empty. With the cell to inspect in A2, =ISBLANK(A2) returns TRUE only if A2 has no contents. A formula in A2 that returns an empty string means A2 is not genuinely empty, so ISBLANK returns FALSE even though the cell may look blank on the worksheet.

By contrast, with the value in A2, =A2<>"" checks the evaluated value. It returns FALSE for a genuinely empty cell and also for a formula result equal to an empty string. This is why ISBLANK and the not-blank comparison can give different answers. Use ISBLANK when you need to know whether anything has been entered in the cell; use the comparison when you care whether the cell’s result is empty.

Neither test treats a cell containing a space as empty. A space is a character, even if it is difficult to see. This is a frequent cause of a “blank” row being counted or highlighted as filled. If users may enter accidental spaces, clean the data or use a whitespace-aware test instead of assuming the cell is empty.

Handle cells containing only spaces

TRIM can remove ordinary leading and trailing spaces before checking whether text remains. With text to inspect in A2, use =LEN(TRIM(A2))>0. For a cell containing only ordinary spaces, the result is FALSE; for a cell containing text such as “Maple Road,” it is TRUE. TRIM also reduces repeated internal ordinary spaces, but that does not affect the basic question of whether any text remains.

Some imported data includes a nonbreaking space, which looks like a normal space but is not removed by TRIM alone. With potentially imported text in A2, use =LEN(TRIM(SUBSTITUTE(A2,CHAR(160)," ")))>0 to replace that character with an ordinary space before trimming. This is a targeted cleanup, not a universal solution for every invisible character. If the source contains tabs or other unusual whitespace, identify and clean those characters too.

These cleanup checks are mainly for text. If your cells may contain numbers, dates, or errors as well, decide how those should be handled before applying a text-cleaning formula across the range. A useful first step is to inspect a problem cell in the formula bar and confirm whether it contains a space, a formula, or an imported character.

Highlight nonblank cells with conditional formatting

Conditional formatting can shade cells that contain a value without adding helper formulas to the sheet. In Excel for Microsoft 365 on Windows, select the range, then choose Home > Conditional Formatting > New Rule > Use a formula to determine which cells to format. Enter a formula based on the first cell in the selected range, choose a format, and confirm the rule.

For a selected range beginning at A2, enter =A2<>"". The reference is relative, so Excel evaluates each cell against its own value as the rule is applied down or across the range. If you select B2:D20 instead, write the formula for B2, the top-left cell. Lock a row or column with dollar signs only when you intentionally want the rule to refer to a fixed location.

If cells may contain formulas that return empty strings, this rule checks the displayed result and will not format those empty-string results. A cell containing spaces, however, can still be formatted. On Mac, the Conditional Formatting command is also on the Home tab; dialog wording or layout may vary slightly by Excel release. Excel for the web supports conditional formatting, though some rule-management options can differ from the desktop app.

Use the test in filters and data checks

The operator is useful in formulas, but you do not have to use it for every task. To find empty or nonempty records in a column, open the filter menu on the column and select or clear the relevant (Blanks) option. The exact list depends on the data and the selected column. Filtering is often quicker when you want to inspect rows, while a formula is more useful when you need a reusable flag or a count.

For data validation and quality checks, consider what “complete” means for the record. A row might have a name but still be missing an email address. Rather than testing the whole row vaguely, test the specific required field. For example, with the required email in C2, use =C2<>"" as the logical test in a status formula. A nonblank result only proves that something is there; it does not prove that the entry is valid or correctly formatted.

For a visible checklist, a helper column can show “Missing” when a required field is empty and “OK” when it is not. This makes exceptions easier to filter and review than a sea of TRUE and FALSE values. Keep the comparison tied to the actual business rule: if a field containing spaces should count as missing, trim or clean it before deciding that the row is complete.

Common mistakes and quick fixes

  • Using ≠ instead of <>: Excel formulas use two angle brackets for “not equal.” The mathematical character ≠ is not the standard formula operator.
  • Leaving out the empty string: Write the complete comparison =A2<>"", not just the operator.
  • Confusing empty with zero: Zero is a value, so the not-blank test returns TRUE for a cell containing 0. If zero should count as missing in your situation, add a separate zero test.
  • Overlooking a formula that displays nothing: ISBLANK sees the formula as cell content, while a comparison to an empty string checks its result. Pick the test that matches your definition.
  • Missing invisible spaces: A space is content. Use TRIM for ordinary spaces or clean imported characters when needed.
  • Applying a conditional-formatting formula to the wrong starting cell: Base the formula on the top-left cell of the selected range, or the rule can shift incorrectly.

Frequently Asked Questions

What is the Excel symbol for not blank?
Use <>"" in a comparison. For example, with the cell in A2, =A2<>"" returns TRUE when its evaluated value is not empty.

How do I count cells that are not blank in Excel?
For a typical range, use COUNTIF with the criterion "<>". If formulas that return empty strings are present and should be excluded, compare the range’s evaluated values with an empty string using SUMPRODUCT.

Why does Excel say a blank cell is not blank?
The cell may contain a space, an invisible imported character, or a formula that returns an empty string. Inspect the cell and choose between a true-empty test, an evaluated-value test, or a whitespace cleanup.

Is ISBLANK the same as checking for <>""?
No. ISBLANK is TRUE only for a genuinely empty cell. A comparison with an empty string can also return FALSE when a formula produces an empty-string result, even though the cell contains a formula.

Does a cell containing 0 count as not blank?
Yes. Zero is a value, so the not-blank comparison returns TRUE and a standard nonblank count includes it. If your rules treat zero as missing, use a separate condition for zero.

Can I highlight cells that are not blank?
Yes. Create a formula-based conditional-formatting rule using the not-blank comparison, written relative to the top-left cell of the selected range. Remember that spaces still count as content.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.