How to Use the LET Function in Excel
LET lets you name a value once and reuse it inside the same formula. The result is shorter, faster, and far easier to read — especially when you keep repeating the same lookup or calculation. Here is how it works.
The quick answer: =LET(name, value, calculation). You name a value once, then use that name in the final calculation. Add as many name/value pairs as you like before the calculation — it makes long formulas shorter, faster, and readable.
The syntax
LET is a list of name/value pairs followed by one final calculation:
=LET(name1, value1, name2, value2, calculation)
Each name must start with a letter. The very last argument is always the calculation that produces the cell's result, and it can use every name you defined before it.
A simple example
=LET(tax, 0.08, price*(1+tax)) names the tax rate tax, sets it to 8%, and then applies it. Change the rate in one place and the whole formula follows. It reads like a short instruction instead of a wall of numbers.
Before and after: a repeated lookup
Here's a formula that looks up an amount and repeats the lookup three times — once to test it, once to display it, once as a fallback:
=IF(XLOOKUP(id,ids,amts)>0, XLOOKUP(id,ids,amts), "none")
With LET, you compute the lookup once, name it, and reuse the name:
=LET(found, XLOOKUP(id,ids,amts), IF(found>0, found, "none"))
Shorter to read, and Excel does the lookup a single time instead of twice.
When to reach for LET
Use it when a formula repeats the same sub-calculation, or when it has grown long enough that you can no longer tell at a glance what it does. Naming the moving parts turns an opaque one-liner into something you — or the next person — can actually read.
#NAME? error. Google Sheets has its own LET with the same idea.Or skip the formula entirely
LET is worth learning, but sometimes you just want the answer, not another formula to maintain. With the Quiriz add-in you can type =QUIRIZ.ASK("total amount for open deals") in a cell and get the answer back in plain English — no nesting, no naming, no lookup to debug. It's a different way to get at the same result.
Get the answer without the formula
Ask a question about your spreadsheet in plain English and get the number back in seconds. Free to start.
Try Quiriz free →