Back to functions
Lookup & Reference2026-09-186 related articles

ROWS Function in Excel

Count the rows in a range or array, including rows with blank cells.

Syntax

ROWS(array)

Arguments

array

Required

The range, array, or array formula whose row count you need.

What it returns

A number representing how many rows the supplied reference or array contains.

What ROWS does

ROWS measures the height of a range or array. Use it to count the rows reserved for a list or returned by another formula. Cell contents do not affect the count.

Practical examples

Count the slots in a short list

Enter North in A2, leave A3 blank, enter South in A4, and enter West in A5.

=ROWS(A2:A5)

The result is 4. The range spans rows 2 through 5, including the blank cell in A3.

Measure a range with several columns

Enter this data in A1:C2:

ABC
102030
405060
=ROWS(A1:C2)

The result is 2. Six cells occupy two rows; the three columns do not increase the row count.

Common mistakes and notes

Blank rows still count

ROWS cannot tell you how many entries are filled in. Use COUNTA when you need to count nonempty cells.

ROW and ROWS answer different questions

ROW gives a worksheet row number. ROWS gives a range's height: ROWS(A8:A10) returns 3, regardless of where the formula is entered.

Supply the range explicitly

The array argument is required. Include only the rows you want measured; a header included in the reference counts as another row.

Related functions

Related articles

Deep dives, troubleshooting guides, and practical examples that use ROWS.

Official documentation