Excel ROWS function
Counts how many rows a range or result has. In Spanish Excel it is called FILAS.
Syntax
English Excel
=ROWS(array)
Spanish Excel (Mexico)
=FILAS(matriz)
Spanish Excel (Spain, Latin America)
=FILAS(matriz)
| Argument | What it is |
|---|---|
| array | The range or result to measure. |
Example
ROWS(range) counts how many rows a range or a result has. Applied to UNIQUE, it tells you how many distinct values there are: customers, products or cities.
=ROWS(UNIQUE(B2:B11))
Common mistake
ROWS(UNIQUE(range)) is the shortest way to count distinct values in Excel 365.
About Ads
This site uses Google AdSense to display ads. These ads help us keep WebHerramientas completely free. Ads are managed by Google and meet strict security and privacy standards.
Ads help us keep WebHerramientas free for everyone
Practice ROWS
Type the formula in the sheet and check it instantly. Spanish or English function names both work. See all lessons
Count distinct: ROWS + UNIQUE
ROWS(range) counts how many rows a range or a result has. Applied to UNIQUE, it tells you how many distinct values there are: customers, products or cities.
In E2, count how many different regions appear.
| A | B | C | D | E | F | |
|---|---|---|---|---|---|---|
| 1 | Salesperson | Region | Amount | Distinct regions | ||
| 2 | Carmen | North | 18,500 | |||
| 3 | Jorge | South | 4,200 | |||
| 4 | Lucía | North | 3,900 | |||
| 5 | Andrés | Central | 21,000 | |||
| 6 | Paola | South | 17,800 | |||
| 7 | Ricardo | North | 6,400 | |||
| 8 | Elena | Central | 5,900 | |||
| 9 | Mateo | North | 19,900 | |||
| 10 | Sofía | West | 800 | |||
| 11 | Diego | Central | 4,600 | |||
| 12 |
Tip: while typing, click a cell or drag across several to insert their reference. F4 anchors the reference with $.
Frequently asked questions
- What is ROWS called in Spanish?
- In Spanish Excel it is FILAS. The formula =ROWS(UNIQUE(B2:B11)) is written =FILAS(UNICOS(B2:B11)) (or with commas in Mexico).
- Why does ROWS use semicolons in some Excel versions?
- It depends on regional settings. Where the comma is the decimal mark (Spain, much of South America), Excel separates arguments with semicolons. English Excel and Mexican Spanish Excel use commas.
- What is the most common ROWS mistake?
- ROWS(UNIQUE(range)) is the shortest way to count distinct values in Excel 365.