Top and Bottom With LARGE and SMALL
Pull the nth largest or smallest value from a range.
Top and Bottom With LARGE and SMALL is a free Excel Formulas Academy lesson on CoddyKit — lesson 4 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the Excel Formulas Academy learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.
Beyond MAX and MIN
MAX gives you the single largest value and MIN the single smallest. But what if you want the 2nd highest, or the 3rd lowest?
That is exactly what LARGE and SMALL do. They let you pull the nth biggest or nth smallest value from a range, which is the foundation of top-N and bottom-N reports.
The LARGE Function
LARGE(range, k) returns the kth largest value. The second argument k picks the position: 1 is the largest, 2 the second largest, and so on.
So LARGE(A2:A20,1) equals MAX(A2:A20), while LARGE(A2:A20,2) gives the runner-up.
=LARGE(A2:A20,2)The SMALL Function
SMALL(range, k) mirrors LARGE from the bottom. SMALL(A2:A20,1) equals MIN(A2:A20), and SMALL(A2:A20,3) returns the third smallest value.
Use SMALL to surface the worst performers, the cheapest options, or the earliest dates in a dataset.
=SMALL(A2:A20,3)Building a Top 3 List
To list the top three values, stack three LARGE formulas with k = 1, 2, 3. A cleaner approach is to reference a helper number so you can fill the formula down.
If cell D2 holds 1, D3 holds 2, and D4 holds 3, this single formula filled down produces the full top-three list.
=LARGE($A$2:$A$20,D2)Using ROW for the k Value
You can generate k automatically with the ROW function so you do not need a helper column. ROW()-1 yields 1 in the first row, 2 in the next, and so on.
Filled down, this builds a ranked list without any extra setup. Adjust the offset to match where your list starts.
=LARGE($A$2:$A$20,ROW()-1)Top N With SEQUENCE
In modern Excel and Google Sheets you can spill an entire top-5 in one formula by feeding SEQUENCE as the k argument. SEQUENCE(5) produces 1, 2, 3, 4, 5.
LARGE then returns five values at once, spilling down automatically. One formula, a full ranked list.
=LARGE(A2:A20,SEQUENCE(5))Summing the Top N
A common business question: what do my top 3 customers contribute? Wrap LARGE in SUM with a SEQUENCE (or an array constant) to total the top values.
The formula below adds the three largest values in the range, giving you the combined top-3 contribution in a single cell.
=SUM(LARGE(A2:A20,{1,2,3}))Watch the k Boundaries
If k is less than 1, or larger than the count of numbers in the range, LARGE and SMALL return the #NUM! error.
For example, asking for the 30th largest value in a list of only 19 numbers fails. Guard against this in reports by wrapping the call in IFERROR.
=IFERROR(LARGE(A2:A20,5),"Not enough data")Pairing With a Label
A value alone is less useful than knowing who earned it. Combine LARGE with INDEX and MATCH to fetch the name attached to the top value.
This finds the largest sales figure, locates its row, and returns the matching name from column A, so your report reads "Top seller: Maria."
=INDEX(A2:A20,MATCH(LARGE(B2:B20,1),B2:B20,0))LARGE and SMALL Ignore Text
Like the other statistical functions, LARGE and SMALL count only numbers. Text and blank cells in the range are skipped, so they do not affect which value is nth largest.
This means you can safely point them at a column that includes a header row. Just watch for numbers accidentally stored as text, since those are ignored and can change which value LARGE or SMALL returns.
=LARGE(A:A,1)Worked Example: Top and Bottom Performers
You have monthly sales in B2:B20. Management wants the best and worst three months.
- Best three:
=LARGE($B$2:$B$20,{1,2,3}) - Worst three:
=SMALL($B$2:$B$20,{1,2,3})
Place each in a cell that can spill, and you instantly have a top-and-bottom snapshot driving your dashboard.
=SMALL($B$2:$B$20,{1,2,3})Quick Check
Test your understanding of LARGE and SMALL.
Recap: LARGE and SMALL
You can now reach beyond MAX and MIN:
LARGE(range,k)returns the kth largest;SMALL(range,k)the kth smallest.- k = 1 matches MAX / MIN; increase k for runners-up.
- Feed
SEQUENCEor an array like{1,2,3}to build or sum a top-N list in one formula. - Pair with INDEX-MATCH to label the value, and wrap in IFERROR to handle out-of-range k.
Frequently asked questions
Is the “Top and Bottom With LARGE and SMALL” lesson free?
Yes — the full text of “Top and Bottom With LARGE and SMALL” is free to read here on the web, and the Excel Formulas Academy course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the Excel Formulas Academy course, upgrade to CoddyKit PRO.
What will I learn in “Top and Bottom With LARGE and SMALL”?
Pull the nth largest or smallest value from a range. You practise Excel Formulas Academy with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.
Do I need any experience to start Excel Formulas Academy?
No prior experience is required. Excel Formulas Academy on CoddyKit is structured for beginners through advanced learners; this is — lesson 4 of 4, so you can start here or from the beginning and move at your own pace.
How long does the “Top and Bottom With LARGE and SMALL” lesson take?
Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.
Can I write and run code in this Excel Formulas Academy lesson?
Yes. Every Excel Formulas Academy lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.
All lessons in this course
- Center With MEDIAN and MODE
- Spread With STDEV and VAR
- Ranking With RANK and PERCENTILE
- Top and Bottom With LARGE and SMALL