Use Excel Formulas to Count Values in Different Cells
Question details
The user needs to count values that meet conditions in different cells and understand whether a formula can increment another cell.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Calculate totals from worksheet values, potentially displaying them in cells such as A25 or A32.
- Observed behavior
- COUNTIF and COUNTIFS return calculated counts; they do not directly change the contents of another cell.
Identify the source cells and the criteria you want to count. Choose an output cell outside the ranges used in its formula to avoid a circular reference.
Count matching values with COUNTIF
Use COUNTIF when you need a total that updates as values in the source cells change.
Click a cell outside the source range, such as A25 if the values are in A1:A24.
Type =COUNTIF(A1:A24,"yes") in the formula bar and press Enter. Replace the range and criterion with your own.
For nonadjacent cells, add separate counts, such as =COUNTIF(A1,"yes")+COUNTIF(A10,"yes").

Count rows that meet multiple conditions with COUNTIFS
Use COUNTIFS when each counted row must meet more than one criterion.
Count matching cells in WPS Spreadsheet
Use COUNTIF or COUNTIFS in WPS Spreadsheet to calculate totals from your worksheet data and update them as the source values change.
- 1. Open your spreadsheet: Open WPS Spreadsheet and select Open to load your workbook.
- 2. Select a result cell: Click a blank cell outside the range you want to count.
- 3. Enter a formula: Type =COUNTIF(A1:A24,"yes") in the selected cell and press Enter. Adjust the range and criterion to match your data.
- 4. Save the workbook: Select File > Save or Save As to save the workbook in your preferred supported format.

Frequently Asked Questions
Can COUNTIF add 1 to another cell?
No. COUNTIF returns a calculated count in the cell containing the formula. To change another cell's stored value, use VBA or calculate the total from source data instead.
How do I count values in nonadjacent cells?
Add separate COUNTIF results in an output cell. For example, =COUNTIF(A1,"yes")+COUNTIF(A10,"yes") counts matches in A1 and A10.
How do I count rows that meet two conditions?
Enter a COUNTIFS formula such as =COUNTIFS(A1:A24,"yes",B1:B24,"complete"). The ranges must have the same dimensions and refer to corresponding rows.
Why does my count formula show a circular reference?
The result cell may be included in its own count range. Move the formula outside that range or edit the range in the formula bar so it excludes the result cell.




