Excel function

INDIRECTfunction

Turns address text such as "C5" into a real reference and returns that cell's value.

All versions
=INDIRECT("C5")
A
B
C
D
1
2
3
4
5
6
7
8
9

Click a cell in the sheet to change the address text. Try a range like "B2:B4" or an invalid address like "Z0". Try breaking it on purpose to see the errors.

Result

6900

ref_text

Text containing a cell or range address. $ makes no difference. This playground handles A1 style only.

What is the INDIRECT function?

=INDIRECT(ref_text, [a1])

INDIRECT turns an address written as text, such as "C5", into a real reference and returns that cell's value.

You can build the address from other cells or with &, so it is used to change the sheet name or row number being referenced. Check on the sheet above which cell the address text points to.

Arguments

ref_text
Text containing a cell or range address.
a1
TRUE (omitted) reads A1 style, FALSE reads R1C1 style. This playground handles A1 only.

INDIRECT examples

  1. Example 1. Basic

    =INDIRECT("C5")

    The value in C5, 6900.

  2. Example 2. Build an address

    =INDIRECT("C"&E1)

    If E1 is 5, it refers to C5.

  3. Example 3. Sum a range

    =SUM(INDIRECT("C2:C4"))

    1500+2300+3200 = 7000.

  4. Example 4. Another sheet

    =INDIRECT("'"&A1&"'!B2")

    Refers to B2 on the sheet named in A1.

Common mistakes

FAQ

Can it refer to a closed workbook?
No. If the target workbook is closed, you get #REF!.
What if the address is invalid?
You get #REF!.