Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.
Last reviewed:
=COUNTIF(B2:B6,"Red")Computed by a real spreadsheet engine on the sample data below.
| Item | Category |
| Apples | Red |
| Bananas | Yellow |
| Cherries | Red |
| Grapes | Purple |
| Lemons | Yellow |
=COUNTIF(B2:B6,"Red")→2
Edit the grid or formula, then run it through a real spreadsheet engine — no signup.
Sample data — click any cell to edit
Need it for your exact data?
Describe your columns in plain English and get the precise formula for your sheet, with the right Excel or Sheets syntax.
No. As of Excel 2024 and Microsoft 365, there is no native worksheet function for this. You need VBA or Power Query.
Custom functions only recalculate when their input arguments change. Changing a fill color is not a value change, so you must manually trigger recalculation (F9 in Excel, or edit any cell in Sheets).
Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.
Last reviewed: