Stack

Learn about the Stack widget in Flutter, which arranges child widgets on top of one another.

We'll cover the following

The Stack is a Flutter widget that holds a list of widgets and arranges them one on top of the other. To put it another way, the Stack enables developers to combine several widgets into a single screen and render them from bottom to top. Whereas Column and Row widgets allow their children to be arranged in a specific direction and have a clear separation, meaning any child widget can not overlap with another child widget.

On the other hand, the children of Stack can overlap each other. Let’s run the following application to understand what a Stack widget can do.

Example

Let’s look at the code below:

Get hands-on with 1400+ tech skills courses.