If you work in accounts, sales or any back-office job, you have probably done this at least once: one sheet has the product list with prices, another sheet has the bill, and you sit there copying prices one by one. It works for ten rows. It falls apart at five hundred.
VLOOKUP fixes exactly this. You give it a code, it goes to your list, finds that code and brings back whatever you ask for from the same row: the name, the price, the city, the salary.
I worked in accounts and MIS for more than ten years, and this was the formula I typed more than any other. Below I’ve explained it the same way I teach it to my students, using small examples you can download and try on your own computer.
What VLOOKUP does, in one line
VLOOKUP searches for a value in the first column of a table and returns a value from another column in the same row. The “V” stands for vertical, because it searches down a column.
The VLOOKUP formula
Four parts. Here is what each one means in plain words:
- lookup_value: what you are searching for. Usually a cell, like the product code in F2.
- table_array: the table to search in. The value you are looking for must be in the first column of this range.
- col_index_num: which column of that table you want back. Count from the left of the table, not from column A of the sheet. The first column of your table is 1.
- range_lookup: type
FALSEfor an exact match. TypeTRUEonly when you are working with slabs or ranges (I’ll show you that in Example 3).
FALSE. Most wrong VLOOKUP answers I see come from leaving this part empty, because Excel then assumes TRUE.Example 1: Find the product name and price from a code
Columns A to D hold a small product list for an office supplies shop: code, name, category and price. In column F we have codes typed on a bill, and we want the name and price next to each code without copying anything by hand.

In G2, type:
Excel takes the code in F2 (P105), looks for it in the first column of A2:D9, finds it in row 6 and returns the 2nd column of the table: Desk Calculator 12-digit.
For the price in H2, only the column number changes. Price is the 4th column of the table, so:
That returns 450. Now select G2:H2 and drag down. Every code gets its own name and price.
$A$2:$D$9 locks the table. Without the dollar signs, the range slides down one row every time you drag the formula, and the last few rows start missing the product list. Press F4 right after selecting the range to add the $ signs in one go.Example 2: Pull a full employee record from one ID
This is the kind of thing HR and accounts teams do every month. You have an employee master list, and you want a small “find employee” box where you type an ID and see the person’s details.

H2 holds the Emp ID we want (E1006). The four formulas below it are the same except for the column number:
- Name:
=VLOOKUP($H$2,$A$2:$E$9,2,FALSE) - Department:
=VLOOKUP($H$2,$A$2:$E$9,3,FALSE) - City:
=VLOOKUP($H$2,$A$2:$E$9,4,FALSE) - Salary:
=VLOOKUP($H$2,$A$2:$E$9,5,FALSE)
Type a different ID in H2, say E1003, and all four answers change to Imran Qureshi, HR, Delhi and 36,000. This one small box can replace a lot of scrolling and Ctrl+F.
Notice that H2 is locked with $H$2 here. That is because every formula points to the same ID cell, so we don’t want that reference to move either.
Example 3: Grades and slabs with approximate match (TRUE)
Exact match is what you will use 90% of the time. But there is one job where TRUE is the right choice: when the answer depends on which range a number falls into. Grades by marks, commission by sales, tax by income slab, discount by order value.

The slab table in A1:B7 says: 0 and above is F, 33 and above is D, 45 and above is C, and so on. In F2:
With TRUE, VLOOKUP doesn’t need an exact 88 in the slab table. It finds the largest value that is less than or equal to 88, which is 75, and returns its grade: A. Harsh’s 59 falls between 45 and 60, so he gets C. Neha’s 92 crosses 90, so she gets A+.
Example 4: VLOOKUP from another sheet
In real files the master list is almost always on a different sheet. The formula is the same; you just add the sheet name before the range. The easiest way is not to type it at all: start the formula, click the other sheet’s tab, select the table, and Excel writes the sheet name for you.
The single quotes appear because the sheet name has a space in it. This exact formula is used in the Practice sheet of the download file, so you can click on it and see how it is built.
Common VLOOKUP errors and how to fix them
VLOOKUP is simple, but it is also strict. Here are the problems I get asked about most, and what is actually going wrong.

#N/A: the value is not in the list
Row 3 above looks for P109, which doesn’t exist in the product list, so plain VLOOKUP shows #N/A. That is correct behaviour, but it looks ugly on a report. Wrap the formula in IFERROR to show a clean message instead:
#N/A even though the value is clearly there
I get asked about this one a lot. In row 4 the code reads “P103”, the list has P103, and still VLOOKUP says #N/A. The reason is an invisible space after the code (it often comes in when data is copied from software or a website). TRIM removes extra spaces before the search:
The other common cause is numbers stored as text. If your IDs are numbers like 1001, check that both the lookup cell and the list have them in the same form. A small green triangle in the corner of a cell usually means a number is stored as text.
#REF!: the column number is too big
If your table is A2:D9 (four columns) and you ask for column 5, Excel has nothing to give you and shows #REF!. Count the columns of your selected range again.
A wrong answer with no error
This is the dangerous one. If you forget FALSE at the end, VLOOKUP does an approximate match and can return the value from a nearby row without any warning. If a result looks odd, check the last part of the formula first.
Where VLOOKUP falls short
VLOOKUP has three weak spots you should know about:
- It only looks to the right. The value you search for must be in the first column of the table. If the code is in column D and the name is in column B, VLOOKUP can’t do it on its own.
- The column number is fixed. If someone inserts a new column inside your table, “4” may now point to the wrong column.
- It returns the first match only. If the same code appears twice, you get the first row.
For these situations, INDEX with MATCH or the newer XLOOKUP function (in Excel 2021 and Microsoft 365) work better. I’ve compared the two in XLOOKUP vs VLOOKUP. For everyday work on any version of Excel, VLOOKUP is still the one you’ll reach for first.
Practice before you move on
Open the Practice sheet in the download file. It has three product codes and two empty columns. Write VLOOKUP formulas to bring the category and the price from the price list sheet. The answers are further down on the same sheet, so try first and check after.
Got all three right? Change the codes in column A to any other codes from the price list and check that your formulas still give the right answers.
Quick questions
Is VLOOKUP case-sensitive?
No. “p105” and “P105” are treated the same.
Can VLOOKUP return more than one column at once?
In Microsoft 365 it can: give it a list of column numbers like {2,4} and the answers spill into the cells next to it. In older versions, write one formula per column and change the column number, as in Example 2.
Does VLOOKUP work in Google Sheets?
Yes. The formula is written exactly the same way, so everything in this guide applies there too.
What should I learn after VLOOKUP?
IF formulas, SUMIF and pivot tables. Together with VLOOKUP, these four cover most of the daily reporting work in an office job, and all of them are part of the Advance Excel Course.
Want to go beyond VLOOKUP? My Advance Excel Course takes you from the basics to formulas, Pivot Tables, MIS reports and dashboards in 90 step-by-step video chapters, explained in Hindi.