How to Use Excel COUNTIFS Formula for Values Between Two Ranges
Question details
The user needs to count records in a spreadsheet that fall between a specific lower and upper numerical range using the COUNTIFS function.

- Product
- Spreadsheet
- Device & OS
- not provided
- Scenario
- Analyzing data and needing to find the total count of entries that meet multiple criteria, specifically those falling within a designated numerical boundary.
- Observed behavior
- The goal is to correctly format the COUNTIFS formula with multiple criteria to evaluate both the lower and upper bounds of a dataset.
Ensure your data is organized in clear columns without merged cells, and identify the specific lower and upper bound values you want to use as your criteria.
Use COUNTIFS with Cell References for Lower and Upper Bounds
This is the most dynamic method, allowing you to reference cells containing your minimum and maximum values to count the records.
By referencing cells instead of typing numbers directly into your formula, you can easily update your lower and upper limits later without having to rewrite the function.
Click on the empty cell (for example, in column H) where you want the final count to be displayed.
Type the formula =COUNTIFS(range, ">="&E2, range, "<="&F2), replacing 'range' with your actual data column, 'E2' with your lower bound cell, and 'F2' with your upper bound cell.
Press Enter on your keyboard to execute the formula and view the total number of records that fall between these two values.

Use COUNTIFS with Hardcoded Numerical Ranges
If your range criteria are fixed and will not change, you can type the numbers directly into the formula instead of referencing other cells.
Count Data Easily with WPS Spreadsheet
WPS Spreadsheet fully supports advanced functions like COUNTIFS, allowing you to seamlessly calculate and analyze data ranges with a familiar interface and 100% compatibility.
- 1. Open your workbook: Launch WPS Spreadsheet and open the document containing the data you want to analyze.
- 2. Access the Function Wizard: Click on the 'Formulas' tab in the top ribbon and select 'Insert Function'.
- 3. Apply COUNTIFS: Search for 'COUNTIFS' in the dialog box, and follow the intuitive prompts to select your data range and input your ">=" and "<=" criteria.

Frequently Asked Questions
Can I use COUNTIFS to count dates between two specific dates?
Yes, dates are treated as numbers in spreadsheets. You can use the same logic, such as =COUNTIFS(A2:A10, ">="&DATE(2023,1,1), A2:A10, "<="&DATE(2023,12,31)) to count entries within a specific date range.
Why is my COUNTIFS formula returning zero?
This usually happens if the criteria syntax is incorrect (e.g., missing quotation marks or the ampersand before a cell reference), or if the data in your range is formatted as text instead of actual numerical values.
What is the difference between COUNTIF and COUNTIFS?
COUNTIF is used to count cells based on a single condition, whereas COUNTIFS allows you to apply multiple conditions across different ranges simultaneously, which is required when setting both a lower and an upper bound.




