Skip to main content

Excel VSTACK function

Author: Siluvia Last Modified: 2022-09-22

The VSTACK function combines multiple ranges or arrays vertically into one large array. And each subsequent array is appended at the bottom of the previous array.

Note: This function is only available in Excel for Microsoft 365 on the Insider channel.

VSTACK function VS. HSTACK function

The VSTACK function can be used to combine ranges vertically, while the HSTACK function can be used to combine ranges horizontally.


=VSTACK(array1, [array2],...)


Array1 (required): The first range or array to append.
Array2,... (optional): The second and more ranges or arrays to append.


1) The VSTACK function returns a single array that has the following dimensions:
The number of rows: It has as many rows as the sum of all the rows of the source arrays;
The number of columns: Equals to the maximum of the column count from each of the array arguments.
2) The resulting array automatically spills into as many cells as needed after entering the formula and pressing the Enter key;
3) The #N/A error value occurs if the given arrays have different columns. If you want to replace the #N/A error with the value you need, please put the HSTACK function inside the IFERROR function. Such as:


Return value

It returns an array.


As shown in the screenshot below, there are two ranges that need to be appended to a single range vertically. You can apply the VSTACK function as follows to get it done.

Select a blank cell, such as C14 in this case, enter the following formula and press the Enter key to get the combined array.


Notes: If the ranges have different columns, #N/A error values will occur in the result array as shown in the screenshot below.

If you want to keep the cell blank when there is no value, you can apply the formula below to get it done.


The Best Office Productivity Tools

Kutools for Excel - Helps You To Stand Out From Crowd

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates  |  Delete Blank Rows  |  Combine Columns or Cells without Losing Data  |  Round without Formula ...
Super VLookup: Multiple Criteria  |  Multiple Value  |  Across Multi-Sheets  |  Fuzzy Lookup...
Adv. Drop-down List: Easy Drop Down List  |  Dependent Drop Down List  |  Multi-select Drop Down List...
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  Compare Columns to Select Same & Different Cells ...
Featured Features: Grid Focus  |  Design View  |  Big Formula Bar  |  Workbook & Sheet Manager | Resource Library (Auto Text)  |  Date Picker  |  Combine Worksheets  |  Encrypt/Decrypt Cells  |  Send Emails by List  |  Super Filter  |  Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters ...)  |  50+ Chart Types (Gantt Chart ...)  |  40+ Practical Formulas (Calculate age based on birthday ...)  |  19 Insertion Tools (Insert QR Code, Insert Picture from Path ...)  |  12 Conversion Tools (Numbers to Words, Currency Conversion ...)  |  7 Merge & Split Tools (Advanced Combine Rows, Split Excel Cells ...)  |  ... and more

Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...


Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)

  • One second to switch between dozens of open documents!
  • Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
  • Increases your productivity by 50% when viewing and editing multiple documents.
  • Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.
Comments (0)
No ratings yet. Be the first to rate!
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
Rate this post:
0   Characters
Suggested Locations