# HSTACK

## Content

The function appends arrays horizontally and in sequence to return a larger array.

>type=note
> **Note**: HSTACK is a dynamic array formula, and you need to enable the dynamic array feature in the Workbook.

## Syntax

`HSTACK(array1, [array2], ...)`

## Arguments

<span data-teams="true">This function has these arguments:</span>

| <span data-teams="true">Argument</span> | <span data-teams="true">Description</span> |
| -------- | ----------- |
| *<span data-teams="true">array1</span>* | <span data-teams="true"> [Required] First array to append</span> |
| *<span data-teams="true">array2, ...</span>* | <span data-teams="true"> [Optional] Additional arrays to append</span> |

## Remarks

The function returns the array formed by appending each of the array arguments in a column-wise fashion. The resulting array will as follows:

* **Rows**: The maximum of the row count from each of the array arguments.
* **Columns**: The combined count of all the columns from each of the array arguments.

## Examples

![hstack-snapshot.png](https://cdn.mescius.io/document-site-files/images/8d606653-16a0-474d-b9dc-e2b4d01c2446/hstack-snapshot.b95441.png)