# COUNTA function in Excel

> COUNTA counts every cell that isn't empty: text, numbers, dates, errors and even formulas that return empty text.

Source: https://spreadsheetpractice.com/functions/counta · Updated October 28, 2026 · Formulas and results on this page were run by the Spreadsheet Practice formula engine on November 20, 2026

## Quick answer

- **What it does:** COUNTA counts every cell that isn't empty: text, numbers, dates, errors and even formulas that return empty text.
- **Syntax:** `=COUNTA(value1, [value2], ...)`
- **Most common use:** `=COUNTA(A2:A6)` returns 5 (Every guest with a name entered)
- **Available in:** Every current version
- **Category:** [Statistical functions](https://spreadsheetpractice.com/functions/category/stats)
- **Returns:** The number of cells that aren't empty.
- **Google Sheets:** Also available in Google Sheets.

## What it does

COUNTA counts every cell that isn't empty: text, numbers, dates, errors and even formulas that return empty text. It's the usual way to count names in a list or responses to a question, and the difference between two COUNTA results shows how many rows are missing something.

## Syntax

`=COUNTA(value1, [value2], ...)`

| Argument | Required? | What it is |
|---|---|---|
| `value1` | Required | The first value, cell or range to count. |
| `value2` | Optional | More values, cells or ranges, up to 255 in total. |

## Examples

Each result was calculated by running the formula on the sample sheet.

| Cell | Formula | Result | What it shows |
|---|---|---|---|
| F2 | `=COUNTA(A2:A6)` | 5 | Every guest with a name entered |
| F3 | `=COUNTA(C2:C6)` | 2 | Guests who left a note |
| F4 | `=COUNTA(A2:A6)-COUNTA(B2:B6)` | 2 | Guests still missing an email address |

### The sample sheet

Every formula above runs on this data:

|  | A | B | C | D | E | F |
|---|---|---|---|---|---|---|
| 1 | Name | Email | Dietary note |  | Check | Result |
| 2 | Ana Diaz | ana@example.com | Vegetarian |  | Guests | 5 |
| 3 | Raj Patel | raj@example.com |  |  | Dietary notes | 2 |
| 4 | Lee Wong |  | Nut allergy |  | Missing emails | 2 |
| 5 | Kim Park | kim@example.com |  |  |  |  |
| 6 | Mo Saleh |  |  |  |  |  |

## Common mistakes

| What you see | Why, and how to fix it |
|---|---|
| The count is higher than expected | Cells with a space or a formula that returns "" aren't empty, so COUNTA counts them. Clear the cells or use COUNTIF(range,"?*") to count real text. |
| Counting a whole column includes the header | COUNTA(A:A) counts the header row too. Subtract 1 or start the range below the header. |

## Tips

- COUNTA of a column is a quick way to find the last row of a list that has no gaps.

## Related functions

- [COUNT](https://spreadsheetpractice.com/functions/count): COUNT tells you how many cells contain numbers.
- [COUNTBLANK](https://spreadsheetpractice.com/functions/countblank): COUNTBLANK counts the empty cells in a range: unassigned tasks, unanswered questions, missing dates.
- [COUNTIF](https://spreadsheetpractice.com/functions/countif): COUNTIF counts the cells in a range that meet one condition: tickets marked "Open", scores of 70 or more, product names containing "lamp".

## Questions

### Does COUNTA count cells with formulas that return blank?

Yes. A formula returning "" is not empty, so COUNTA counts it. COUNTBLANK counts it as blank, which is why the two don't always add up to the range size.

### How do I count cells that contain text only?

Use =COUNTIF(A2:A6,"*"), which counts text and skips numbers.

## Practice

A graded COUNTA exercise ("Counting cells") is on [the COUNTA page](https://spreadsheetpractice.com/functions/counta). It is checked instantly, then re-checked on changed data.

Lessons that use COUNTA:

- [Lesson 2: SUM, AVERAGE, MIN, MAX & COUNT](https://spreadsheetpractice.com/learn/sum-average-min-max-count)
- [Lesson 22: Splitting and counting list cells](https://spreadsheetpractice.com/learn/textsplit-count-clean-lists) (Pro)

---

Spreadsheet Practice (https://spreadsheetpractice.com) teaches spreadsheet formulas by practice: every exercise is graded in a live grid and re-checked on changed data.
