Count nonblank cells

Important notice for users of Office 2003    To continue receiving security updates for Office, make sure you're running Office 2003 Service Pack 3 (SP3). The support for Office 2003 ends April 8, 2014. If you’re running Office 2003 after support ends, to receive all important security updates for Office, you need to upgrade to a later version such as Office 365 or Office 2013. For more information, see Support is ending for Office 2003.

Let's say you want to find out how many people entered project hours this week or how many products sold on a specific day. To count nonblank cells, use the COUNTA function.

Example

The example may be easier to understand if you copy it to a blank worksheet.

ShowHow to copy an example

  1. Create a blank workbook or worksheet.
  2. Select the example in the Help topic.

 Note   Do not select the row or column headers.

Selecting an example from Help

Selecting an example from Help
  1. Press CTRL+C.
  2. In the worksheet, select cell A1, and press CTRL+V.
  3. To switch between viewing the results and viewing the formulas that return the results, press CTRL+` (grave accent), or on the Formulas tab, in the Formula Auditing group, click the Show Formulas button.
 
1
2
3
4
5
6
A
Data
Sales
19
TRUE
Formula Description (Result)
=COUNTA(A2:A6) Counts the number of nonblank cells in the list above (3)
=COUNTA(A2:A3, A6) Counts the number of nonblank cells in the top two, and bottom cell in the list (1)

Function details

COUNTA

 
 
Applies to:
Excel 2003