Press Enter to search  ·  Esc to close

Inherited a formula you don't understand and can't touch?

You open a workbook built by someone else and find a monster formula like this in a key cell. No comments. No documentation. You have no idea what it does, whether it's reliable, or if it's safe to touch.

Home
Insert
Formulas
Data
Review
C2
fx
=IFERROR(INDEX(Sales!$C$2:$C$500,MATCH(1,(Sales!$A$2:$A$500=A2)*(Sales!$B$2:$B$500=B2),0)),"")

This is super common in corporate Excel. You inherit files and need to understand them before you can use them, modify them, or explain them to your boss. Manually reverse-engineering these formulas takes forever. Claude is excellent at this — just paste the formula, give a bit of context, and it breaks everything down layer by layer.

Function
What it does
Risk / notes
IFERROR
Outermost wrapper — catches any error and returns "" (blank) instead
Safe — hides errors cleanly
INDEX
Returns the value from column C of the Sales sheet at the row MATCH identifies
Range hardcoded to row 500 — breaks if data exceeds this
MATCH
Finds the row where both column A = A2 AND column B = B2 simultaneously
Array formula — must be entered with Ctrl+Shift+Enter in older Excel
(*) multiply
Multiplies two TRUE/FALSE arrays — acts as AND logic between the two conditions
Classic array trick — returns 1 only when both conditions are TRUE
Cell C2 — Documentation (generated by Claude)
DOCUMENTATION sheet
This formula looks up a value from the Sales sheet by matching two criteria simultaneously — the value in column A must match A2, and the value in column B must match B2. When both match, it returns the corresponding value from column C. If no match is found, it returns a blank cell. Known risk: the lookup ranges are hardcoded to row 500 — if the Sales sheet ever exceeds 500 rows, extend the ranges to avoid missing data.
Documented Jun 2026
Explanation by Claude AI
Review if Sales sheet grows beyond 500 rows
  • You paste any complicated formula and Claude explains it in plain English
  • Claude points out the risky parts — hardcoded ranges, dangerous assumptions, array formula requirements
  • Claude turns the explanation into clear documentation you can share with colleagues
  • Claude tells you what you can safely change and what you should leave alone

Array formulas: the MATCH(1,(...)*(...),0) pattern is a classic array formula technique for multi-criteria lookup. In Excel 365 it works normally. In Excel 2019 or older it must be entered with Ctrl+Shift+Enter — Claude will flag this automatically.

Six steps — from copying the formula correctly to having documented, trusted knowledge of what it does.

01

Copy the formula from the formula bar

Click the cell, then copy the formula directly from the formula bar — not from the cell itself. The cell usually shows the result, not the actual formula.

02

Gather a bit of context

Note the sheet name, the cell address, and what the cell appears to show — a name, a number, a date. Also note any other sheet names mentioned in the formula. Claude needs to know what those sheets contain.

03

Paste into Claude with context

Give Claude the formula plus a short description of what the workbook is for. Ask it to explain the formula step by step, starting from the outermost function.

04

Ask follow-up questions

After the first explanation, ask specific things: "What happens if the value in A2 isn't found?", "Can I extend the range to row 1000?", "What would break if I rename the Sales sheet?" Claude answers each question in context.

05

Create documentation

Ask Claude to write a plain-English paragraph suitable for a colleague. Paste this into the workbook as a cell comment or in a dedicated DOCUMENTATION sheet.

06

Check safety before changing anything

Before modifying the formula or the data it uses, ask Claude what the consequences would be. This helps you avoid breaking other parts of the file you didn't know were connected.

Tip: If Claude's first explanation is still confusing, ask it to explain the formula as if you're a non-Excel user. Then ask a second time for the technical detail. Two passes at different levels of detail almost always give you a complete picture.

Copy these prompts into Claude. Replace the bracketed placeholders with your actual formula and context.

Core explanation prompt

Prompt — paste into Claude
I inherited an Excel workbook and need to understand this formula. It's in cell [e.g. C2] on sheet [name]. The formula is: [paste formula] The workbook is used for [brief description, e.g. monthly sales reporting]. The sheets referenced contain [short description]. Please explain this formula layer by layer, starting from the outermost function. Tell me what each part does, what it returns, and any risks if I change something.

Follow-up questions prompt

Prompt — paste into Claude
Based on your explanation: 1. What happens if the lookup value in A2 doesn't exist in the data? 2. Is it safe to extend the ranges to row 1000? 3. What would break if I renamed the Sales sheet?

Documentation prompt

Prompt — paste into Claude
Please write a clear, plain-English documentation paragraph for this formula that a non-technical colleague could understand. Include what it calculates, what inputs it needs, and any known risks or fragile parts.
Checklist
Formula copied from the formula bar, not the cell value
Sheet name, cell address, and workbook purpose noted
Context included when pasting into Claude
Claude explanation read layer by layer and verified against the sheet
Follow-up questions asked for any unclear parts
Documentation added as cell comment or in a Documentation sheet
Pre-change safety check done before touching formula or its dependencies
Important: Claude explains the formula based on what you paste and describe. If the sheet names or data structure are unusual, include that in your prompt — it affects the explanation significantly.