How to Look Up Excel Prices by Item and Demand Tier
Question details
The user needs to retrieve specific price values from a table based on two criteria: an exact item match and a tiered demand threshold.

- Product
- Excel
- Device & OS
- not provided
- Scenario
- Calculating tiered pricing based on different items and variable weekly demand volumes.
- Observed behavior
- The goal is to accurately pull the corresponding price using a two-way lookup where the column header match is approximate (the largest tier that does not exceed average weekly demand) and the row match is exact.
Ensure your demand tiers in the header row are formatted as numbers and sorted in ascending order (e.g., 1000, 5000, 10000) for approximate match functions to evaluate correctly.
Use a Nested XLOOKUP for Exact and Approximate Matches
Use a nested XLOOKUP formula to find the exact item and the appropriate demand tier using the exact or next smaller match mode.
XLOOKUP is highly versatile and allows you to perform two-way lookups. The inner XLOOKUP retrieves the entire row of prices for a specific item, while the outer XLOOKUP searches the demand tier headers to find the correct column.
Click on the cell where you want the resulting tiered price to appear.
Type the formula to find the item row. For example: XLOOKUP(A6, $G$6:$G$12, $H$6:$O$12). Here, A6 is your item, G6:G12 is the item list, and H6:O12 is the price grid.
Enclose the inner formula within another XLOOKUP to match the demand tier: =XLOOKUP(B6, $H$5:$O$5, XLOOKUP(A6, $G$6:$G$12, $H$6:$O$12), 0, -1). Here, B6 is the demand, and H5:O5 contains the numeric tier headers.
Press Enter. The -1 match mode ensures it selects the exact tier or the largest tier that does not exceed your demand.

Use LET, INDEX, and XMATCH for Text-Based Headers
If your headers contain text (like '5K' or '10K'), extract the numbers first using REGEXEXTRACT, then use INDEX and XMATCH.
Calculate Tiered Pricing Effortlessly with WPS Spreadsheet
WPS Spreadsheet fully supports advanced dynamic array functions like XLOOKUP, LET, and XMATCH, making complex two-way lookups and tiered pricing calculations simple and efficient.
- 1. Open your tiered pricing workbook: Launch WPS Spreadsheet and open the document containing your pricing table and demand data.
- 2. Start your XLOOKUP formula: Click on the target cell and type =XLOOKUP( to begin your calculation.
- 3. Select your lookup arrays: Use the intuitive formula tooltips to select your lookup values, header arrays, and set the match mode to -1.
- 4. Calculate instantly: Press Enter to instantly calculate your tiered prices across your entire dataset.

Frequently Asked Questions
Why is my XLOOKUP returning an #N/A error for the demand tier?
This usually happens if the demand value you are looking up is smaller than the lowest tier in your header row, or if you forgot to set the match mode argument to -1 (exact match or next smaller item).
Do my tier headers need to be sorted for XLOOKUP to work?
Unlike traditional VLOOKUP or MATCH with match type 1, XLOOKUP does not explicitly require the lookup array to be sorted for exact matches. However, for approximate match modes (like -1), your data must be structured logically, and sorting ascending ensures accurate threshold calculations.
Can I use VLOOKUP and MATCH instead of XLOOKUP?
Yes, you can use =VLOOKUP(item, table_array, MATCH(demand, header_row, 1), FALSE). However, the header row must be strictly numeric and sorted in ascending order for MATCH to return the correct column.




