Ravindra BagaleCourses & study guides Track your progress

Excel LOOKUP Function

Chala mitrano — classic LOOKUP is approximate by design. Great for slabs; risky for IDs. For exact IDs use XLOOKUP or VLOOKUP FALSE.

Fictional sample data for learning. Discount slabs for a Coimbatore electronics shop + a small US web cart ($).

Purpose

Classic approximate lookup along a vector: find a value in one range and return from a parallel range. Prefer XLOOKUP for new work.

Return value

Approximate match from result_vector (largest value ≤ lookup_value when sorted ascending).

Syntax

LOOKUP(lookup_value, lookup_vector, [result_vector])

Arguments

ArgumentRequired?Description
lookup_valueRequiredValue to find (approximate).
lookup_vectorRequiredOne row or column of sorted ascending keys.
result_vectorOptionalParallel range of results. If omitted, LOOKUP uses array form rules.

Version

All modern Excel and LibreOffice Calc. Kept for legacy sheets; teach XLOOKUP for new models.

How to use — Why → What → How

Why: Price breaks and tax slabs need “which band does this amount fall into?” Classic LOOKUP is approximate by design and expects ascending keys. Coimbatore electronics shops use it for discount slabs; US web carts use dollar shipping bands the same way. It ...

What: LOOKUP finds the largest key ≤ lookup_value in a sorted vector and returns the parallel result. Read the arguments table carefully; each one changes the answer in a specific way.

How — numbered steps:

  1. Sort keys ascending.
  2. Type =LOOKUP(.
  3. Enter the amount.
  4. Select the key vector, then the result vector.
  5. Enter and spot-check band edges.
  6. Compare your result with the Answers sheet only after you attempt it.
  7. Write one sentence in your own words explaining when you would use this function at work.

Ravindra Bagale's Tip

Friends, sort the lookup_vector ascending or LOOKUP can return baffling answers.

Ravindra Bagale's Tip

Do not use LOOKUP for unsorted employee codes. Interviews may still ask it — know the slab pattern.

Ravindra Bagale's Tip

Friends, after class open a blank sheet and rebuild one LOOKUP example without looking. That memory test beats re-reading the page.

Download practice file: practice-lookup.xlsx (includes sheet About this data, practice sheets, and Answers).

Worked examples

1) Discount slab

Coimbatore shop: order value → discount %.

Order from (₹)Discount
00%
20005%
50008%
1000012%
Formula: =LOOKUP(6500, A2:A5, B2:B5)

Result: 8%

What it means: Largest key ≤ 6500 is 5000 → 8%.

2) Edge of a band

Exact boundary 5000.

Order from (₹)Discount
00%
20005%
50008%
Formula: =LOOKUP(5000, A2:A4, B2:B4)

Result: 8%

What it means: Exact key matches that band.

3) Below first key behaviour

Tiny order 50 on a sheet that starts at 0.

Order from (₹)Discount
00%
20005%
Formula: =LOOKUP(50, A2:A3, B2:B3)

Result: 0%

What it means: Falls into the first band.

4) US cart $ slab

Web cart thresholds in dollars.

Order from ($)Ship
0$8
50$4
100Free
Formula: =LOOKUP(72, A2:A4, B2:B4)

Result: $4

What it means: Largest key ≤ 72 is 50 → $4 shipping.

5) Why not for IDs

Unsorted codes — LOOKUP may “match” wrongly.

CodeName
C-30Asha
C-10Ben
C-20Chen
Formula: =LOOKUP("C-20", A2:A4, B2:B4)

Result: (unreliable on unsorted text)

What it means: Text approximate rules are confusing — use XLOOKUP exact instead.

6) Classroom recap

Quick check before you close the LOOKUP lesson.

Order from (₹)Discount
00%
20005%
50008%
Formula: =LOOKUP(6500, A2:A5, B2:B5)

Result: 8%

What it means: Same pattern as example 1 — rebuild it from memory on the Practice sheet, then check Answers.

About this data. Small demo rows for learning. Real sheets are longer; the same formula pattern scales when columns are clean.

Common errors and fixes

Wrong band — Keys not sorted ascending. Fix: Sort the lookup_vector.
#N/A — lookup_value smaller than the first key in some cases. Fix: Add a 0 band or guard with IF.
Silent wrong ID match — Used LOOKUP on unsorted codes. Fix: Switch to XLOOKUP/VLOOKUP FALSE.

Notes and tips

  • Array form LOOKUP(lookup_value, array) exists but confuse learners — teach vector form first.
  • XLOOKUP with match_mode -1 can replace many LOOKUP slabs with clearer arguments.
  • Classic LOOKUP is approximate by design and expects ascending keys. Coimbatore electronics shops use it for discount slabs; US web carts use dollar shipping bands the same way. It is the wrong tool for unsorted SKUs — results look confident and wrong. For new models, XLOOKUP with match_mode -1 can express the same slab logic with clearer arguments. Still learn LOOKUP so you can read legacy finance sheets.
  • LOOKUP slabs vs VLOOKUP TRUE: similar idea. XLOOKUP match_mode -1 is the clearest modern spelling of approximate band logic.
  • Fictional sample data only — practice amounts and names are made for learning.
  • After you finish the 10 tasks, re-read the errors table once; most class mistakes are listed there.
  • Keep ranges locked with absolute references when you copy formulas down a column of inputs.
  • Say the business question in plain words before you type the equals sign — it prevents wrong arguments.

In real work

Classic LOOKUP is approximate by design and expects ascending keys. Coimbatore electronics shops use it for discount slabs; US web carts use dollar shipping bands the same way. It is the wrong tool for unsorted SKUs — results look confident and wrong. For new models, XLOOKUP with match_mode -1 can express the same slab logic with clearer arguments. Still learn LOOKUP so you can read legacy finance sheets.

How it compares

LOOKUP slabs vs VLOOKUP TRUE: similar idea. XLOOKUP match_mode -1 is the clearest modern spelling of approximate band logic.

Interview corner

Is LOOKUP exact or approximate?
Approximate (vector form).
Must keys be sorted?
Yes — ascending for reliable results.
What should replace it for IDs?
XLOOKUP or VLOOKUP with FALSE.

XLOOKUP, VLOOKUP, MATCH, HLOOKUP

Practice tasks (10)

  1. Task 1. Return discount % for order ₹6,500.
    Hint: sorted Order-from column.
  2. Task 2. Return discount for exactly ₹5,000.
    Hint: boundary should hit the 5000 band.
  3. Task 3. Return shipping for a $72 US cart.
    Hint: $ slab sheet.
  4. Task 4. Add a note explaining why LOOKUP is bad for unsorted SKUs.
    Hint: approximate behaviour.
  5. Task 5. Rebuild the same slab with XLOOKUP match_mode -1 if your Excel supports it.
    Hint: compare results.
  6. Task 6. Sort a messy key column and re-test LOOKUP.
    Hint: ascending order.
  7. Task 7. Try an amount below 0 band and record the result.
    Hint: may be #N/A.
  8. Task 8. Document vector vs array form in one sentence.
    Hint: teach vector form.
  9. Task 9. Return discount for ₹12,000.
    Hint: top band.
  10. Task 10. Bonus: chart the slabs for class.
    Hint: simple column chart of thresholds.

Quick quiz

Q1. Classic LOOKUP is best for:
Q2. lookup_vector should be sorted:
Q3. For exact product codes prefer:
Q4. LOOKUP(6500, …) on bands 0/2000/5000/10000 returns the band for:
Q5. LOOKUP is removed from Microsoft 365.

Answers: Q1=Sorted slabs, Q2=Ascending, Q3=XLOOKUP or VLOOKUP FALSE, Q4=5000, Q5=False (check after you try).

Revision card

Standalone card (no tip or photo strip). QR opens this lesson. Download the PNG and revise offline.

Revision card: LOOKUP
LOOKUP revision card