---
title: "COUNTIFS practice: 4 exercises with answers | ExcelSavvy"
description: "Practice COUNTIFS in Excel: count rows with two conditions, numbers between two limits and orders between two dates, checked instantly."
canonical_url: "https://excelsavvy.com/practice/countifs"
meta:
  "og:description": "Practice COUNTIFS in Excel: count rows with two conditions, numbers between two limits and orders between two dates, checked instantly."
  "og:image": "https://excelsavvy.com/_og/d/c_Page%2Ctitle_~Q09VTlRJRlMgcHJhY3RpY2U6IDQgZXhlcmNpc2VzIHdpdGggYW5zd2Vycw%2Cdescription_~UHJhY3RpY2UgQ09VTlRJRlMgaW4gRXhjZWw6IGNvdW50IHJvd3Mgd2l0aCB0d28gY29uZGl0aW9ucywgbnVtYmVycyBiZXR3ZWVuIHR3byBsaW1pdHMgYW5kIG9yZGVycyBiZXR3ZWVuIHR3byBkYXRlcywgY2hlY2tlZCBpbnN0YW50bHku%2Ceyebrow_Excel%2Bpractice%2Bexercises%2Csite_practiceexcel%2Cprops_eyJncmlkIjp7ImNvbHMiOlsiQSIsIkIiLCJDIiwiRSJdLCJyb3dzIjpbeyJuIjoxLCJjZWxscyI6WyJSZWdpb24iLCJQcm9kdWN0IiwiU2FsZXMiLCJOb3J0aCBvdmVyIDQwMCJdfSx7Im4iOjIsImNlbGxzIjpbIk5vcnRoIiwiU2hvZXMiLCI1MDAiLCIiXX0seyJuIjozLCJjZWxscyI6WyJTb3V0aCIsIlNob2VzIiwiMzAwIiwiIl19LHsibiI6NCwiY2VsbHMiOlsiTm9ydGgiLCJCYWdzIiwiMjUwIiwiIl19LHsibiI6NSwiY2VsbHMiOlsiTm9ydGgiLCJTaG9lcyIsIjQyMCIsIiJdfSx7Im4iOjYsImNlbGxzIjpbIlNvdXRoIiwiQmFncyIsIjE4MCIsIiJdfV0sInRhcmdldCI6WzEsM119fQ%2Cp_Ii9wcmFjdGljZS9jb3VudGlmcyI%2Cs_N0aD9Qkyax6m8zRK.png"
  "og:image:height": "600"
  "og:image:type": image/png
  "og:image:width": "1200"
  "og:title": "COUNTIFS practice: 4 exercises with answers | ExcelSavvy"
  "twitter:image": "https://excelsavvy.com/_og/d/c_Page%2Ctitle_~Q09VTlRJRlMgcHJhY3RpY2U6IDQgZXhlcmNpc2VzIHdpdGggYW5zd2Vycw%2Cdescription_~UHJhY3RpY2UgQ09VTlRJRlMgaW4gRXhjZWw6IGNvdW50IHJvd3Mgd2l0aCB0d28gY29uZGl0aW9ucywgbnVtYmVycyBiZXR3ZWVuIHR3byBsaW1pdHMgYW5kIG9yZGVycyBiZXR3ZWVuIHR3byBkYXRlcywgY2hlY2tlZCBpbnN0YW50bHku%2Ceyebrow_Excel%2Bpractice%2Bexercises%2Csite_practiceexcel%2Cprops_eyJncmlkIjp7ImNvbHMiOlsiQSIsIkIiLCJDIiwiRSJdLCJyb3dzIjpbeyJuIjoxLCJjZWxscyI6WyJSZWdpb24iLCJQcm9kdWN0IiwiU2FsZXMiLCJOb3J0aCBvdmVyIDQwMCJdfSx7Im4iOjIsImNlbGxzIjpbIk5vcnRoIiwiU2hvZXMiLCI1MDAiLCIiXX0seyJuIjozLCJjZWxscyI6WyJTb3V0aCIsIlNob2VzIiwiMzAwIiwiIl19LHsibiI6NCwiY2VsbHMiOlsiTm9ydGgiLCJCYWdzIiwiMjUwIiwiIl19LHsibiI6NSwiY2VsbHMiOlsiTm9ydGgiLCJTaG9lcyIsIjQyMCIsIiJdfSx7Im4iOjYsImNlbGxzIjpbIlNvdXRoIiwiQmFncyIsIjE4MCIsIiJdfV0sInRhcmdldCI6WzEsM119fQ%2Cp_Ii9wcmFjdGljZS9jb3VudGlmcyI%2Cs_N0aD9Qkyax6m8zRK.png"
---

> Index of every page on this site: [llms.txt](https://excelsavvy.com/llms.txt)

# **COUNTIFS practice exercises**

Count rows that meet several conditions at once, including a number between two limits.

[**Start the first exercise**](https://excelsavvy.com/practice/countifs/countifs-two-conditions)

COUNTIFS(

## **How COUNTIFS works**

COUNTIFS counts the rows where every one of your conditions is met. It takes pairs of arguments: a range to test and a criterion, repeated for each condition. It works the same in Excel and Google Sheets.

`**=COUNTIFS(A2:A9,"North",C2:C9,">400")**` counts the North orders with sales over 400. To count numbers between two limits, use the same range twice: `**=COUNTIFS(B2:B8,">=18",B2:B8,"<=30")**` counts the people aged 18 to 30, both ages included. Put a limit in a cell by joining it to the operator, as in `**">="&F2**`.

Unlike SUMIFS there is no sum range, so the result is always a count of rows. All the ranges must be the same size. For a single condition COUNTIF is shorter. The exercises below cover two conditions, counting between two numbers, counting orders between two dates, and conditions taken from cells.

1. [**1****COUNTIFS with two conditions**In E2, use COUNTIFS to count the North orders with Sales over 400.](https://excelsavvy.com/practice/countifs/countifs-two-conditions)
2. [**2****Count between two numbers with COUNTIFS****Premium**In E2, use COUNTIFS to count the people in B2:B8 aged 18 to 30, both ages included. Use the same range twice, once for each limit.](https://excelsavvy.com/practice/countifs/countifs-between-two-numbers)
3. [**3****Count the orders between two dates****Premium**In F3, count the orders dated from F1 to F2, both days included. Use the date column twice in COUNTIFS and join each operator to its cell: ">="&F1 and "<="&F2.](https://excelsavvy.com/practice/countifs/countifs-between-two-dates)
4. [**4****COUNTIFS with the conditions in cells****Premium**In F3, count the reps from the region in F1 with sales of at least the amount in F2. Point at both cells: F1 as it is, and F2 joined to ">=".](https://excelsavvy.com/practice/countifs/countifs-criteria-from-cells)

## **Functions in this topic**

- [**COUNTIFS**](https://excelsavvy.com/functions/countifs)

## **Read the guide**

- [**Excel test for a job interview: what it looks like and how to practice**](https://excelsavvy.com/learn/excel-for-job-interviews)
- [**Excel practice data: free datasets with tasks and answers**](https://excelsavvy.com/learn/excel-practice-data)
- [**Excel inventory data: free practice file with tasks and answers**](https://excelsavvy.com/learn/excel-inventory-data)
- [**Excel customer data: free practice file with tasks and answers**](https://excelsavvy.com/learn/excel-customer-data)

## **Questions**

<details>

<summary>

### How do I use COUNTIFS with OR logic?

</summary>

COUNTIFS only combines conditions with AND. For OR, add one COUNTIFS per option, as in =COUNTIFS(A2:A9,"North")+COUNTIFS(A2:A9,"South"). That is fine when a row can match only one of them. If a row can match both, subtract the rows that match both, or it will be counted twice.

</details>

<details>

<summary>

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

</summary>

Put wildcards around the word, as in =COUNTIFS(A2:A9,"\*desk\*"). The \* stands for any number of characters, so it counts "Desk lamp" and "Standing desk". The match ignores upper and lower case. Add more range and criterion pairs to count only the rows that also meet other conditions.

</details>

<details>

<summary>

### Why does COUNTIFS return 0 when I can see matches?

</summary>

A common cause is a cell reference inside the quotes, such as "&gt;=F2". Excel then compares with the text "F2". Write "&gt;="&amp;F2 instead. Other causes are extra spaces in the data, numbers stored as text, and dates that are text. Check one condition at a time to find the culprit.

</details>

```json
{"@context":"https://schema.org","@graph":[{"@id":"https://excelsavvy.com/#identity","@type":"Organization","name":"ExcelSavvy","url":"https://excelsavvy.com/","logo":{"@id":"https://excelsavvy.com/#logo"}},{"@id":"https://excelsavvy.com/#website","@type":"WebSite","inLanguage":"en-US","name":"ExcelSavvy","url":"https://excelsavvy.com/","alternateName":["Excel Savvy","ExcelSavvy.com","PracticeExcel","Practice Excel Online"],"publisher":{"@id":"https://excelsavvy.com/#identity"},"workTranslation":[{"@id":"https://excelopgaver.dk/#website"},{"@id":"https://excelpraxis.de/#website"}]},{"@id":"https://excelsavvy.com/practice/countifs#webpage","description":"Practice COUNTIFS in Excel: count rows with two conditions, numbers between two limits and orders between two dates, checked instantly.","name":"COUNTIFS practice: 4 exercises with answers","url":"https://excelsavvy.com/practice/countifs","@type":["WebPage","CollectionPage","FAQPage"],"breadcrumb":{"@id":"https://excelsavvy.com/practice/countifs#breadcrumb"},"isPartOf":{"@id":"https://excelsavvy.com/#website"},"mainEntity":[{"@id":"https://excelsavvy.com/practice/countifs#/schema/question/1"},{"@id":"https://excelsavvy.com/practice/countifs#/schema/question/2"},{"@id":"https://excelsavvy.com/practice/countifs#/schema/question/3"}],"potentialAction":[{"@type":"ReadAction","target":["https://excelsavvy.com/practice/countifs"]}],"primaryImageOfPage":{"@id":"https://excelsavvy.com/#logo"}},{"@id":"https://excelsavvy.com/practice/countifs#breadcrumb","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","name":"Home","item":"https://excelsavvy.com","position":1},{"@type":"ListItem","name":"Excel practice exercises","item":"https://excelsavvy.com/practice","position":2},{"@type":"ListItem","name":"COUNTIFS practice: 4 exercises with answers","position":3}]},{"@id":"https://excelsavvy.com/practice/countifs#/schema/question/1","@type":"Question","inLanguage":"en-US","name":"How do I use COUNTIFS with OR logic?","acceptedAnswer":{"@type":"Answer","text":"COUNTIFS only combines conditions with AND. For OR, add one COUNTIFS per option, as in =COUNTIFS(A2:A9,\"North\")+COUNTIFS(A2:A9,\"South\"). That is fine when a row can match only one of them. If a row can match both, subtract the rows that match both, or it will be counted twice."}},{"@id":"https://excelsavvy.com/practice/countifs#/schema/question/2","@type":"Question","inLanguage":"en-US","name":"How do I count cells that contain certain text?","acceptedAnswer":{"@type":"Answer","text":"Put wildcards around the word, as in =COUNTIFS(A2:A9,\"*desk*\"). The * stands for any number of characters, so it counts \"Desk lamp\" and \"Standing desk\". The match ignores upper and lower case. Add more range and criterion pairs to count only the rows that also meet other conditions."}},{"@id":"https://excelsavvy.com/practice/countifs#/schema/question/3","@type":"Question","inLanguage":"en-US","name":"Why does COUNTIFS return 0 when I can see matches?","acceptedAnswer":{"@type":"Answer","text":"A common cause is a cell reference inside the quotes, such as \">=F2\". Excel then compares with the text \"F2\". Write \">=\"&F2 instead. Other causes are extra spaces in the data, numbers stored as text, and dates that are text. Check one condition at a time to find the culprit."}},{"@id":"https://excelsavvy.com/#logo","@type":"ImageObject","caption":"ExcelSavvy","contentUrl":"https://excelsavvy.com/brand/practiceexcel/icon-512.png?v=3","inLanguage":"en-US","url":"https://excelsavvy.com/brand/practiceexcel/icon-512.png?v=3"}]}
```

## Sitemap

See the full [sitemap](https://excelsavvy.com/sitemap.md) for all pages.
