BYROW Function
Runs a LAMBDA on each row of a range and returns one result per row.
Category
Logical
Available in
Microsoft 365, Excel 2024
Returns
A spilled column, one result per row
Overview
BYROW hands your LAMBDA one whole row at a time. Whatever single value the LAMBDA returns becomes that row's answer.
It's a one-formula way to get row totals, row maximums, or a TRUE/FALSE check per row.
Syntax
=BYROW(array, lambda(row)) Explain
Arguments
| Argument | Required? | What it does |
|---|---|---|
| array | Yes | The range to work through, row by row. |
| lambda | Yes | A LAMBDA with one parameter (the row) that returns a single value. |
Examples
Example 1 — Total per rep
Add up each rep's three quarters.
E2fx=BYROW(B2:D5, LAMBDA(r, SUM(r)))
| A | B | C | D | E | |
|---|---|---|---|---|---|
| 1 | Rep | Q1 | Q2 | Q3 | Total |
| 2 | Ana | 120 | 150 | 130 | 400 |
| 3 | Ben | 90 | 110 | 100 | 300 |
| 4 | Cara | 200 | 180 | 220 | 600 |
| 5 | Dev | 80 | 95 | 75 | 250 |
=BYROW(B2:D5, LAMBDA(r, SUM(r))) Explain
Example 2 — Did every quarter reach 100?
AND works on the whole row here, because BYROW passes one row at a time.
=BYROW(B2:D5, LAMBDA(r, AND(r>=100))) Explain
Returns TRUE for Ana and Cara, FALSE for Ben (90 in Q1) and Dev.
Common mistakes
- #CALC! errors. The LAMBDA returned more than one value for a row. BYROW needs exactly one result per row.
Notes
- In current Microsoft 365 you can pass a function name directly: =BYROW(B2:D5, SUM).
- Related functions: BYCOL, MAP, LAMBDA, REDUCE.

Author
Kyle Stott
Certified Microsoft Excel Expert
Kyle has worked professionally with Microsoft Excel for over a decade and has consulted on and taught Excel best practices to over 400 companies across 30+ countries.