Matheasy

COUNTIF()

Returns a conditional count across a range.

Syntax
fx
=COUNTIF(range, criterion)
Try it
F2
→
8
Sample data · sales.csv
ABCD
1CompanyRegionQuarterRevenue
2Acme CoWestQ118,400
3Acme CoWestQ222,100
4Acme CoWestQ331,700
5Acme CoWestQ448,200
6GlobexEastQ114,200
7GlobexEastQ219,800
8GlobexEastQ323,400

Common pitfalls

  • Criteria like ">100" must be quoted as a string, including the comparison operator.
  • COUNTIF is single-criterion only. For multiple conditions reach for COUNTIFS.
  • Empty cells and "" are NOT the same. COUNTIF(A:A, "") only counts truly empty cells.
Related formulas
COUNTIFS()
Returns the count of a range depending on multiple criteria.
Used by
COUNTIFS()
Returns the count of a range depending on multiple criteria.