Write Readable Formulas by Naming Values with LET
A formula that repeats the same calculation two or three times is hard to read and easy to break — you edit one copy of the expression, forget the other, and the numbers silently drift apart.
Excel & Google Sheets
This formula works in both Excel and Google Sheets.
How it works
LET works in name/value pairs: total is defined as SUM(B2:B10), count as COUNTA(B2:B10), and the final argument is the calculation that uses them — total/count, the average order value. Each piece is computed once and reused by name, which makes long formulas dramatically easier to read and often faster, because the spreadsheet no longer recalculates the same expression several times. Names must start with a letter and can't look like a cell reference — dealTotal works, D1 doesn't. LET needs Excel 365 or Excel 2021; anything older shows #NAME?. Google Sheets added LET in 2023 with identical syntax, so current Sheets runs the exact same formula unchanged.
When to use it
Use it whenever a formula repeats an expression — a lookup used in both an IF test and its result, one total feeding several ratios — or when a formula has grown too dense for the next person to follow.
Common mistakes
Did this formula help?
Human-reviewedLast reviewed 2026-07-08