# COUNTA

Formulas / COUNTA
To count the number of cells that contain data.
COUNTA(value1, [value2], ...)
• value1 - the values to count
• value2 - [OPTIONAL] the values to count
• COUNT takes up to 255 values as arguments

## Examples

• =COUNTA(B5:B15)

returns 9 if there are 9 cells with data in the range B5:B15.

• =COUNTA(1,2,3)

returns 3 because there are 3 values as arguments.

• =COUNTA(1,"a","b")

returns 3 because there are 3 values as arguments.

• =COUNTA(1,2,3,"a",5%)

returns 5 because there are 5 values as arguments.

• =COUNTA(A1:A10)

returns the count of non-empty cells in the range A1:A10.

• =COUNTA(A1:A10,C1:H2)

returns the count of non-empty cells in two ranges.

## Summary

The COUNTA function is a built-in function in Sourcetable that is used to count the number of cells that contain data.

• COUNTA does not count empty cells
• COUNTA counts numbers, text, logical values, error values, and empty strings (""). A workaround should be used if you do not want to count empty strings
• COUNTA counts invisible characters, which are characters that make a cell look empty even though the cell is the empty string "" returned from another formula.
• Use COUNT instead of COUNTA if you only want to count numbers.

What is the COUNTA function?
The COUNTA function is an inbuilt statistical Sourcetable function that can count cells.
What types of data values can the COUNTA function count?
The COUNTA function can count cells containing several types of data values, including text, numbers, Boolean values, date/time values, error values, and empty text strings.
What is the return value of the COUNTA function?
COUNTA returns a numeric value.
To which function family does the COUNTA function belong?
The COUNTA function belongs to the family of COUNT functions.
When should COUNTIF be used instead of COUNTA?
COUNTIF should be used instead of COUNTA to count cells meeting certain conditions.
What is the difference between COUNTA and COUNT?
COUNTA gets an exact count of cells that contain data, while COUNT only counts cells with numeric data.