TAKE
Return a set number of rows or columns from the start or end of an array with TAKE.
Spreadsheet editor
Spreadsheet editor
Syntax
=TAKE(array, rows, [columns])
Returns: Array Arguments
| Argument | Required | Description |
|---|---|---|
| array | Yes | The range or array you want to trim. |
| rows | Yes | The number of rows to return. Use a negative number to count from the end of the array. |
| columns | No | The number of columns to return. Use a negative number to count from the end of the array. |
About
Use TAKE when you need a live top-N or bottom-N view that resizes itself when your data changes. It pairs well with SORT and SORTBY, so you can rank a table first and then keep only the top few rows. It is also handy for trimming a FILTER result down to a short preview.
TAKE is a dynamic array function, so the result spills into the cells next to your formula. If you want to remove rows or columns instead of keeping them, use DROP, which is the mirror image of TAKE.
Exercises using TAKE
Examples
Show the last few rows
Spreadsheet editor
Trim rows and columns at once
Spreadsheet editor
Build a top-3 leaderboard
Spreadsheet editor
Watch out for
Using zero for rows or columns
Setting rows or columns to 0 returns a #CALC! error because TAKE cannot return an empty array.
→ Use at least 1 for the count, or use a negative number to take from the end instead of 0.
Asking for more than exists
You expect TAKE to pad the result when you request more rows than the array has.
→ TAKE returns only what is available, so asking for 10 rows from a 6-row array simply returns all 6. There is no error and no padding.
Spill range is blocked
The result needs to spill into nearby cells, but something is already in the way, so you see a #SPILL! error.
→ Clear the cells next to your formula so the array has room to expand.
Function not available
TAKE returns a #NAME? error in older Excel versions that do not include it.
→ TAKE needs Microsoft 365 or Excel for the web. On older versions, use INDEX to pull specific rows instead.