> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://help.sigmacomputing.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://help.sigmacomputing.com/_mcp/server.

# Use stacks to make responsive layouts (Beta)

> Use the Stack layout type in Sigma for responsive workbook layouts. Elements arrange automatically by direction, distribution, and alignment.

This documentation describes one or more public beta features that are in development. Beta features are subject to quick, iterative changes; therefore the current user experience in the Sigma service can differ from the information provided in this page.

This page should not be considered official published documentation until Sigma removes this notice and the beta flag on the corresponding feature(s) in the Sigma service. For the full beta feature disclaimer, see [Beta features](/docs/sigma-product-releases#beta-features).

Using the **Stack** layout type, you can configure [containers](/docs/use-containers-to-organize-workbook-layouts) that change their layouts responsively as you add new elements. Similar to the <a href="https://en.wikipedia.org/wiki/Flexbox" target="_blank">CSS Flexible Box Layout Model</a>, a stack arranges all elements automatically based on a specified layout direction, distribution, and alignment, rather than requiring you to manually place each element in a grid.

![A user converts a grid layout container to a stack layout container, and then automatically arranges and resizes its elements to fill the container](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/5c536c0c00c0521b38c2cc67476664291cf2777c4a142de17d25ae5b3c692a4e/assets/docs-images/stack-intro.gif?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=81373f1a86ea4f24aeb004ed04ba61b8c1eabdc36e51ac59f61b3d97c7fb3b07&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)

Use a stack when you want to:

* Arrange and size elements dynamically across a container
* Iterate quickly on designs that might change

This document covers how to configure and customize containers with the **Stack** layout type, as well as their elements.

## User requirements

The ability to create and customize a stack requires the following:

* You must be assigned an [account type](/docs/account-type-and-license-overview) with the **Create, edit, and publish workbooks** permission enabled.
* You must be the workbook owner or be granted **Can edit** access to the workbook.

## Limitations

* The **Wrap** option is only available when **Direction** is set to **Row**.

## Add a stack to your workbook

You can create a stack by converting a container to use the **Stack** layout type, or by grouping existing elements into a new stack.

### Convert a container to a stack

1. In the **Add element** bar, select **Layout** then **Container**.
2. Select the container, then in the editor panel, open the **Format** section.
3. Set the **Type** to **Stack**.

The container updates to use the default stack layout.

### Group elements into a stack

1. On the canvas, select multiple elements.
2. In the selection crumb menu, select **Create horizontal stack** or **Create vertical stack**.

The selected elements appear in a new stack using the direction you chose.

## Customize the layout of elements in a stack

The **Stack** layout type changes how all elements in a container are arranged. Instead of placing and sizing each element at a specific position in a grid, elements are arranged automatically based on the layout configuration of the stack, and change size in response to other elements.

By default, a stack arranges all elements in a single column, with each element sized to fill the width of the container.

To customize a stack, you can do the following:

* [Set the layout for a stack](#set-the-layout-for-a-stack)
* [Apply a Quick stack preset](#apply-a-quick-stack-preset)
* [Customize sizing for elements in a stack](#customize-sizing-for-elements-in-a-stack)

### Set the layout for a stack

You can change the orientation, spacing, and arrangement of elements in a stack:

1. Select the container.

2. In the editor panel, under **Format**, open the **Layout** section.

3. For **Direction**, select the axis to arrange elements in the container on:

   | Option                                                                                                                            | Details                                                                                                                                                   |
   | :-------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------- |
   | <img src="https://sigma-docs-screenshots.s3.us-west-2.amazonaws.com/Icons/arrow-right-short.svg" alt="" /> <strong>Row</strong>   | Distribute elements across the container left-to-right. Optionally, turn on the **Wrap** toggle to arrange elements across multiple rows based on sizing. |
   | <img src="https://sigma-docs-screenshots.s3.us-west-2.amazonaws.com/Icons/arrow-down-short.svg" alt="" /> <strong>Column</strong> | Distribute elements down the container's length.                                                                                                          |

4. For **Distribute**, select how elements are arranged along the selected **Direction**:

   | Option            | Details                                                                                                                                                                          |
   | :---------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   | **Start**         | Place elements starting at the left side of the container if **Direction** is set to **Row**, or starting at the top of the container if **Direction** is set to **Column**.     |
   | **Center**        | Place elements starting at the center of the container, expanding towards the edges as more elements are added to the container.                                                 |
   | **End**           | Place elements starting at the right side of the container if **Direction** is set to **Row**, or starting at the bottom of the container if **Direction** is set to **Column**. |
   | **Space between** | Place the first and last elements at the edges of the container, with remaining elements evenly spaced between them.                                                             |

5. For **Align**, select how elements are arranged along the axis perpendicular to the selected **Direction**:

   | Option     | Details                                                                                                                                                            |
   | :--------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   | **Start**  | Align elements with the left side of the container if **Direction** is set to **Column**, or with the top of the container if **Direction** is set to **Row**.     |
   | **Center** | Align elements with the center of the container.                                                                                                                   |
   | **End**    | Align elements with the right side of the container if **Direction** is set to **Column**, or with the bottom of the container if **Direction** is set to **Row**. |

6. Configure spacing settings for the elements:

   | Option      | Details                                                                                                                                                   |
   | :---------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------- |
   | **Padding** | Adds padding between the elements and the edge of the container. Turn off the toggle to remove padding.                                                   |
   | **Gap**     | Adds a gap between elements in the container. Turn off the toggle to remove all space between elements.                                                   |
   | **Wrap**    | Wrap elements onto a new row. Only available when **Direction** is set to **Row**. Turn off the toggle to place all elements in the container in one row. |

### Customize sizing for elements in a stack

You can configure elements in a stack with unique sizing options that aren't available in the **Grid** layout type, allowing you to size elements responsively based on their own contents or other elements in the container.

After placing an element in a stack:

1. Select the element.
2. In the editor panel, select **Properties**.
3. In the **Size** section, select an option for the **Width** and **Height** settings:

   | Option          | Details                                                                                                                                                                                                                                                                                                                       |
   | :-------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   | **Fill**        | The element fills the available space along the selected axis. Optionally, set a factor for the element to fill relative to other elements in the stack. For example, if there are two elements set to **Fill**, you can set one of them to **3x** fill to have it take three times the space of an element with **1x** fill. |
   | **Fit content** | The element resizes to display its own contents. For example, a button element with **Fit content** dynamically resizes based on the length of the **Text** in the button.                                                                                                                                                    |
   | **Fixed**       | The element fills a specific size, in pixels. You can manually set the size to create custom static layouts.                                                                                                                                                                                                                  |

The available sizing options depend on the element type. For example, viz and image elements can't use **Fit content**, and some elements have no configurable **Height**.

### Apply a Quick stack preset

You can configure common layouts in a single click by selecting a preset from the **Quick stacks** menu.

![A user opens the Quick stacks menu and switches between two presets, automatically reconfiguring the container's elements](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/27c2c6ef2e92fc42beab5f577eebec7109122c6802c0e976922dfa8fc4498838/assets/docs-images/quick-stacks.gif?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=a7ef3a8ecccb748b2231a25faec2f942ce0015dd2a265c5cb5755dff1d2908ea&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)

To use **Quick stacks**:

1. Add elements to the stack.
2. Select the container.
3. In the editor panel, under **Format**, open the **Quick stacks** section.
4. Select a preset to arrange and size the elements in the stack. To see all available presets, select **More**.

Each preset sets the direction, distribution, and element sizing for the stack in a single step. Applying a preset overwrites the current layout settings.

The following presets set **Direction** to **Row**, arranging elements horizontally:

| Preset                                                                                                                                                                                 | Result                                                                               |
| :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :----------------------------------------------------------------------------------- |
| ![Two elements arranged in a row, aligned to the left of the container.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/5b5fd7dd7e80dfd2b792402c7e5a7f7af5e0905f978861315ce116169ef0b424/assets/docs-images/quick-stack-horizontally-stacked-left.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=bd7b8b53140dfba1a0068479c8704e627586d1293fcbca72b871f78ddb52a751&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)                                            | Elements arranged horizontally, aligned to the left, each sized to fit its content.  |
| ![Two elements arranged in a row, centered horizontally in the container.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/457ea9de690012020018b8a890693afa1ab58369d7b814f29fceac3bed17e950/assets/docs-images/quick-stack-horizontally-stacked-middle.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=641de6de542e58044b57b2ca90cf1b975df9fc18b1d424379d6573d35cb77e6e&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)                                        | Elements arranged horizontally, centered, each sized to fit its content.             |
| ![Two elements arranged in a row, aligned to the right of the container.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/326e874dbacd085b29b859d243c90bd87a7e48e37969d42aa50046e18e9deb21/assets/docs-images/quick-stack-horizontally-stacked-right.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=14f40c6912970d8b2293d3d915293cb069ce57c2f24a991f1fab65e9e918c81b&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)                                          | Elements arranged horizontally, aligned to the right, each sized to fit its content. |
| ![Two elements arranged in a row, each expanded to fill the container width.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/c93bb4a7cc3bcb77f3c7a229f1ca2d1e447f17d7170e2291f53edcf0c14c86ae/assets/docs-images/quick-stack-horizontally-stacked-filling-width.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=6d11d0bee1966b0b4a9816407b3def7174b90a25411ed3609d2ce0ce1ff3927c&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)                              | Elements arranged horizontally, each filling the available width.                    |
| ![Two elements arranged in a row, filling the full width and height of the container.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/e4ca88232fd989f53e5d17074a01d5890c8f612ea552864c242c7e0673fb6dd7/assets/docs-images/quick-stack-horizontally-stacked-centered-filling-width-and-height.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=3ce867166ad5de03f9f979e3a3806a6b9c3aa343631f2ba3f5c6557cbccf7f32&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject) | Elements arranged horizontally, each filling the available width and height.         |

The following presets set **Direction** to **Column**, arranging elements vertically:

| Preset                                                                                                                                                                                 | Result                                                                                 |
| :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------- |
| ![Two elements stacked in a column at the top center of the container.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/01c7402d590c26fb7f440d9e0cd8f0fdfff2746bc8898158947d0abccafd8585/assets/docs-images/quick-stack-vertically-stacked-top-center.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=f3988070b51e5a1d8401246ef6861d35d36d88a81fad1a8afac5e81d999c4661&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)                                         | Elements stacked vertically at the top center, each sized to fit its content.          |
| ![Two elements stacked in a column at the top, each expanded to fill the container width.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/20f3b499938c2a19ac73a02ba71653247f004f978bea3c93aba2ef61230fccce/assets/docs-images/quick-stack-vertically-stacked-top-filling-width.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=8af8d10a96355e2c1d75ded3d81ecd7d5a6d08ed72212a746519637bf3f8c9d6&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)               | Elements stacked vertically at the top, each filling the available width.              |
| ![Two elements stacked in a column, centered vertically, each filling the container width.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/1846532468bdce7cac66061d94e037019327d8b0064ec11bdb5a9d8e7916a75f/assets/docs-images/quick-stack-vertically-stacked-centered-filling-width.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=8b5a5593766b96d0b185c218c5e307ce3bef46c39ef70c6ce5e4208d19bdef5d&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject)         | Elements stacked vertically and centered, each filling the available width.            |
| ![Two elements stacked in a column, filling the full width and height of the container.](https://fdr-prod-docs-files-public.s3.us-east-1.amazonaws.com/sigma.docs.buildwithfern.com/4d6edd498fa65d8137202716dab1620b3b819287ab996d92cddb8fdf6ab26782/assets/docs-images/quick-stack-vertically-stacked-centered-filling-width-and-height.svg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIA6KXJSKKNFOCF7G4B%2F20260804%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260804T154038Z&X-Amz-Expires=604800&X-Amz-Signature=023a59f924a0bb46eb5dbece66370ead7a3c42b1d3e25b7f2b92d69b0647ee55&X-Amz-SignedHeaders=host&x-amz-checksum-mode=ENABLED&x-id=GetObject) | Elements stacked vertically and centered, each filling the available width and height. |

## Related resources

* [Use containers to organize workbook layouts](/docs/use-containers-to-organize-workbook-layouts)