FormulaCraft

How to look up and return multiple values in Excel and Google Sheets

Topic:Lookups (any direction)

Heads up: Excel and Google Sheets do this differently.

Excel
=IFERROR(INDEX(B2:B6,SMALL(IF(A2:A6="Alpha",ROW(A2:A6)-ROW(A2)+1),ROW()-ROW(C2)+1)),"")
Google Sheets
=FILTER(B2:B6,A2:A6="Alpha")

Verified example

Computed by a real spreadsheet engine on the sample data below.

CategoryItem
AlphaApple
BetaBanana
AlphaAvocado
GammaGrape
AlphaApricot

=IFERROR(INDEX(B2:B6,SMALL(IF(A2:A6="Alpha",ROW(A2:A6)-ROW(A2)+1),ROW()-ROW(C2)+1)),"")

Try it with your data

Edit the grid or formula, then run it through a real spreadsheet engine — no signup.

Sample data — click any cell to edit

Runs server-side · free · no signup

Step by step

  1. 1In Google Sheets, enter =FILTER(B2:B6,A2:A6="Alpha") in an empty cell; results spill downward automatically.
  2. 2In Excel 365 use =FILTER(B2:B6,A2:A6="Alpha") — it works identically and also spills.
  3. 3In older Excel, enter the array formula =IFERROR(INDEX(B2:B6,SMALL(IF(A2:A6="Alpha",ROW(A2:A6)-ROW(A2)+1),ROW()-ROW(C2)+1)),"") with Ctrl+Shift+Enter, then copy it down as many rows as you expect matches.
  4. 4Replace "Alpha" with a cell reference (e.g. E2) to make the lookup value dynamic.

Tips

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.

Frequently asked

What happens when there are no matches?

Wrap FILTER in IFERROR to display a custom message: =IFERROR(FILTER(B2:B6,A2:A6="X"),"No results").

Can I return matches from multiple columns?

Yes — expand the return range to include all desired columns, e.g. =FILTER(A2:B6,A2:A6="Alpha").

More on Lookups (any direction)

See all →

Formulas used

Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.

Last reviewed: