Going Stellar

Home/Google Sheets reference

Google Sheets function · Lookup

INDIRECT in Google Sheets: syntax and examples

INDIRECT takes a cell address written as text and returns what that cell holds. This lets you build an address from other cells, for example a row number or a sheet name. The reference is invisible to Sheets, so it does not follow when rows move.

Syntax

INDIRECT(cell_reference_as_string, [is_A1_notation])

Arguments

ArgumentTypeRequiredWhat it does
cell_reference_as_stringtextyesA reference written as text, such as "B2" or "B2:B4", optionally with a sheet name.
is_A1_notationbooleannoTRUE (default) reads A1 notation. FALSE reads R1C1 notation.

Examples

The examples use this table, starting in A1:

ItemQtyRow
Lamp123
Chair0
Stand7
=INDIRECT("B2")

Result: 12

A fixed address written as text returns that cell.

Run in a Google Sheet (English US locale) on .

=INDIRECT("A"&C2)

Result: Chair

Build the address from a value: C2 holds 3, so this reads A3.

Run in a Google Sheet (English US locale) on .

=SUM(INDIRECT("B2:B4"))

Result: 19

A text range works anywhere a range does.

Run in a Google Sheet (English US locale) on .

=INDIRECT("R4C2", FALSE)

Result: 7

With FALSE the text is read as R1C1: row 4, column 2.

Run in a Google Sheet (English US locale) on .

=INDIRECT(ADDRESS(2, 1))

Result: Lamp

ADDRESS builds the text, INDIRECT turns it into a reference.

Run in a Google Sheet (English US locale) on .

Common errors

  • The text must be a valid address. An empty string, "Z" or a sheet that does not exist returns #REF!.
  • R1C1 text needs FALSE as the second argument. Without it, "R4C2" is read as A1 notation and fails with #REF!.
  • The address is plain text. Insert or delete rows and INDIRECT keeps pointing at the old position.
  • Heavy use can slow large files. Prefer INDEX where a fixed reference is enough.

Compared with Excel

Same syntax as Excel INDIRECT. Sheets reads the second argument the same way: FALSE means R1C1.

Questions and answers

How do I point INDIRECT at another sheet?

Put the sheet name and an exclamation mark in the text: "Sheet2!A1". If the name has spaces, wrap it in single quotes.

Sources

  1. INDIRECT (Docs Editors Help)

Markdown version · All functions