WPS Office

Free All-in-One Office Suite with PDF Editor


Edit Word, Excel, and PPT for FREE.


Read, edit, and convert PDFs with the powerful PDF toolkit.


Microsoft-like interface, easy to use.

Free Download

Windows • MacOS • Linux • iOS • Android


Use COUNTIF function for conditional statistics

Uploaded time: September 30, 2021 Difficulty Intermediate

Use COUNTIF function for conditional statistics

Use COUNTIF function for conditional statistics

COUNTIF is a statistical function. It is often used to count the number of cells that meet the criteria. This function can not only count numbers and text but also can count expressions. So how can we use this function?

The grammatical structure of the COUNTIF function is: COUNTIF(Range, Criteria)

Range is the cell range that meets the criteria.

Criteria are the conditions that need to be counted.

Now we have a table that records everyone's afternoon tea order information. Column B contains the persons' names who ordered, and column C records the ordered food of afternoon tea. We now need to calculate the amount of Cheesecake that we have ordered.

Click cell F7 and click Insert Function to find the COUNTIF function. Click the OK button, now a dialog box will pop up.

Since we want to count the amount of Cheesecake in this table of afternoon tea order information, enter C3:C29 in the Range.

Enter Cheesecake in Criteria, or click cell E7. After clicking the OK button, we can quickly count the specific amount of Cheesecake.

In the same way, we can also count the number of orders for Blueberry Cheese Bread and Fried Chicken.This is the basic use of the COUNTIF function. Did you get it?

This skill could be also used in Microsoft Office Excel and Openoffice.

15 years of office industry experience, tech lover and copywriter. Follow me for product reviews, comparisons, and recommendations for new apps and software.