ProofDrill

COUNTIFS

Counts the rows that meet every condition.

Worked example

How many vans need a service and are over 80,000 km?

D2=COUNTIFS(B2:B5,"Due",C2:C5,">80000")

RowABCD
1VanServiceKmBook first
2V-1Due91,0002
3V-2Fine120,000
4V-3Due46,000
5V-4Due83,000

Ranges and conditions come in pairs, and every pair must match.

How to write it

=COUNTIFS(criteria_range1, criteria1, [criteria_range2, criteria2], …)

criteria_range1
The first column to test.
criteria1
What that column must match.
criteria_range2, criteria2, …
More pairs. All must match.
Part of Pro

Try COUNTIFS yourself

The tasks for this function are part of Pro, which isn’t on sale yet. The lesson and its worked example are open to everyone.

See the lesson

Watch out for

  • Every range must be the same size, or Excel returns #VALUE!.
  • Pairs are joined with “and”. For “or”, add two COUNTIFS.

Practise it