< Go Back

If a cell is not blank

What is the “If a cell is not blank” formula?

The “If a cell is not blank” formula was developed based on the IF function, and it prompts the document to automatically take a specific action if a specific cell is not blank (essentially, if the cell contains any entry of some sort). It is possible for you to want to take a specific action if a cell is not blank in your Microsoft Excel worksheet. As opposed to wasting your time on trying to do this manually, this is a simple formula that can help you out.




  • Cell_num – this is a reference to the cell that is to be assessed whether it is blank or not.
  • < > – is a logical operator which means “not equal to“.
  • “” – this is to represent “empty”.
  • cell_num<>”” – this, therefore, means “if cell is not empty”.
  • [value_if_TRUE] – this is the text string that would be displayed if the cell is not blank. e.g. “Closed”, “cell occupied”, “Not empty
  • [value_if_FALSE] – This is the text string that would be displayed if the cell is blank or empty. e.g. “Open”, “cell empty”, “Empty


How to use the If the cell is not a blank formula

The spreadsheet in this example has 3 cells to be assessed; two occupied and one empty.

The following steps should be taken;

  1. Open the spreadsheet that contains the cells to be assessed.


  1. Let’s start with the cell B3 containing “food”. Click on the cell (C3), where the results (whether or not the cell is occupied) would be displayed.


  1. Insert the formula; =IF(B3<>””,”cell occupied”,”cell empty”) into the cell.


  1. Press Enter on your keyboard. “cell occupied” should be displayed, as the cell is obviously occupied by the word “food”.


  1. Next up, we assess the 2nd cell (B4), which is empty, by the way. Insert the formula =IF(B4<>””,”cell occupied”,”cell empty”) and press Enter.


  1. Lastly, let us assess cell B5 that contain a number. Insert the formula =IF(B5<>””,”cell occupied”,”cell empty”) and Press Enter. The result is “cell occupied”.

Cell B5 contains a number “27”, it is not blank.



*Always use quotation marks if your arguments are in form of text.



Microsoft Excel has a function devoted to testing for blank cells called ISBLANK. To use the ISBLANK function in this case, wrap ISBLANK inside the NOT function like this:

=IF(NOT(ISBLANK(B3)),"cell occupied","cell empty")

Our customers love us!
“The expert was absolutely amazing and stuck with me the whole way through. They were polite, patient, seemed to want to genuinely help me and provided a solution that I would never have managed otherwise. I could not be more thankful for their support and solution. Thank you!” - - Chris T, in California
This blog is one way to figure it out. A 20 minute chat session with an expert is a better way.Get step-by-step guidance on your question

Leave a Comment