Skip to main content

Excel VLOOKUP for Beginners... Simple Examples (Step by Step)

How to Look Up Data Fast Without Endless Scrolling Have you ever scrolled through a massive Excel sheet, pressing Ctrl+F over and over just to pull one price or one name? With 20 rows it barely slows you down. Once you hit 500 or 1,000 rows, manual hunting gets exhausting fast. That is the exact bottleneck VLOOKUP fixes. You hand Excel a code or name, it scans down the first column of your table, and it brings back a matching detail from the same row. Type a product code and get the price. Enter an index number and pull a student's name. Work through the two quick examples below inside your own spreadsheet as you read—hands-on practice makes the logic stick much faster. The 4 parts of a VLOOKUP formula =VLOOKUP(lookup_value, table_array, col_index_num, [range_lookup]) The syntax looks dense at first glance, yet every piece has a straightforward job: Part What it does lookup_value The value you want to find, such as a product code, ID, or index number table_array...

Excel VLOOKUP for Beginners... Simple Examples (Step by Step)

How to Look Up Data Fast Without Endless Scrolling

Have you ever scrolled through a massive Excel sheet, pressing Ctrl+F over and over just to pull one price or one name? With 20 rows it barely slows you down. Once you hit 500 or 1,000 rows, manual hunting gets exhausting fast.

That is the exact bottleneck VLOOKUP fixes. You hand Excel a code or name, it scans down the first column of your table, and it brings back a matching detail from the same row.

Type a product code and get the price. Enter an index number and pull a student's name. Work through the two quick examples below inside your own spreadsheet as you read—hands-on practice makes the logic stick much faster.

The 4 parts of a VLOOKUP formula

=VLOOKUP(lookup_value, table_array, col_index_num, [range_lookup])

The syntax looks dense at first glance, yet every piece has a straightforward job:

PartWhat it does
lookup_valueThe value you want to find, such as a product code, ID, or index number
table_arrayThe cell range containing your data. Your lookup column must sit as the leftmost column in this range
col_index_numThe column number holding your result, counted from left to right inside the table (1, 2, 3...)
range_lookupFALSE requires an exact match. TRUE finds the closest match without going over (useful for grading scales and price tiers)

Example 1: Look up a price using a product code

Picture a small shop keeping its price list in range A1:C6:

A (Code)B (Item)C (Price, Rs.)
P001Pen50
P002Exercise Book180
P003Pencil30
P004Calculator1,850
P005School Bag3,500

Excel table with product codes, item names and prices in rupees

Enter a code such as P004 in cell E2. To pull its price automatically into F2, enter:

=VLOOKUP(E2,$A$2:$C$6,3,FALSE)

Here is how each argument works in this formula:

  1. E2 points to the product code you want to search for.
  2. $A$2:$C$6 defines the data table itself, leaving out the header row.
  3. 3 tells Excel to return data from the third column of that table (the price).
  4. FALSE forces an exact match so Excel only returns a result for an identical code.

With P004 in E2, Excel returns 1850. Swap 3 for 2 and you get "Calculator" instead. Once you see that column index shift, the whole function clicks.

VLOOKUP formula returning the price for code P004


Regional separator tip: Depending on your system's regional settings, Excel may expect semicolons instead of commas. If you hit a formula syntax error, test =VLOOKUP(E2;$A$2:$C$6;3;FALSE).

Example 2: Convert exam marks into letter grades

For ranges rather than exact codes, switch the final argument to TRUE. Instead of hunting for one identical number, you ask Excel which grade threshold a score clears.

Suppose your grading scale sits in E2:F6. Sort the lower mark limits from smallest to largest, or approximate matching will misfire:

E (Marks from)F (Grade)
0F
35S
50C
65B
75A

With student scores in column B, put this formula in C2 and fill it down:

=VLOOKUP(B2,$E$2:$F$6,2,TRUE)
StudentMarksGrade
Kamal82A
Nimali68B
Dilini59C
Sunil45S

Take a score of 68. Excel scans down to the largest threshold that does not exceed 68, lands on 65, and returns B.


VLOOKUP with TRUE turning exam marks into grades


Using different cutoffs at your school or college? Update the numbers in the lookup table and keep the formula intact.

5 common VLOOKUP mistakes that trip people up

  1. Putting the lookup key outside the first column. VLOOKUP only searches the leftmost column of table_array. Reorder your columns or switch to XLOOKUP.
  2. Omitting FALSE on exact lookups. Leave it out and Excel can default to approximate matching without warning, returning wrong rows on codes or names. Always pass FALSE for exact matches.
  3. Leaving trailing spaces in cells. A value like "P004 " will not match "P004". Clean the lookup cell with TRIM: =VLOOKUP(TRIM(E2),$A$2:$C$6,3,FALSE).
  4. Forgetting dollar signs before dragging down. Without absolute references, your lookup range shifts downward row by row. Lock it as $A$2:$C$6 by selecting the range and pressing F4.
  5. Picking a column index larger than the table. Requesting column 4 inside a 3-column table triggers a #REF! error.
Expert Insight: In real-world finance and operations sheets, exported codes often mix text formatting in one file with stored numbers in another. When a numeric lookup fails for no obvious reason, multiplying the lookup value by 1 (such as E2*1) converts text-numbers into real numbers. If it's the other way round (numbers in your lookup, text in the table), use E2&"" instead.

Troubleshooting a #N/A error

A #N/A result means Excel could not locate your lookup value in the first column of the selected table. Run through these quick checks first:

  • Do the characters, spelling, or numbers match identically?
  • Are there invisible leading or trailing spaces? Try wrapping the lookup value in TRIM.
  • Is one side stored as text while the other is stored as a number?

The #N/A error from a VLOOKUP formula

To display a clean message instead of a raw error when a code is missing, wrap the formula inside IFNA:

=IFNA(VLOOKUP(E2,$A$2:$C$6,3,FALSE),"Not found")

Using TRIM and IFNA to fix VLOOKUP errors

Should you switch to XLOOKUP instead?

If you run Microsoft 365 or Excel 2021, XLOOKUP gives you extra flexibility: it searches any column—not just the leftmost one—and avoids counting column index numbers.

Even so, Excel 2019 and older versions lack XLOOKUP. When you share workbooks across mixed Excel versions, VLOOKUP remains the safest compatibility pick. Our dedicated XLOOKUP guide is coming soon. 

Frequently asked questions

What does the "V" in VLOOKUP stand for?

It stands for Vertical, because the function searches downward through a column.

Can VLOOKUP pull values from a column to the left?

No. VLOOKUP only returns values from columns to the right of the lookup column. Use XLOOKUP or INDEX/MATCH when you need to look left.

Can VLOOKUP reference data on another worksheet?

Yes. Reference the sheet name before the range, for example: =VLOOKUP(A2,Sheet2!$A$2:$C$100,3,FALSE).

Does VLOOKUP work in Google Sheets too?

Yes, Google Sheets supports the same VLOOKUP syntax and behavior.

What is the practical difference between TRUE and FALSE?

FALSE returns an exact match only. TRUE returns the closest match less than or equal to the lookup value, provided the first column is sorted in ascending order.


Want more practical spreadsheet workflows? Explore our Excel productivity and AI tips guide. Share this post with a teammate still scanning long sheets by hand, or leave a comment below if a formula gives you trouble.

Comments