DESIGN & PRACTICE

Figma Auto Layout: When to Use Hug, Fill, and Fixed

One notification. Three ways to decide its size.

Figma Auto Layout original concept example
Original examples · illustrative web demos, not Figma recordings

01Group content by its job

Our notification has a title, a description, and a View button. The title reads “Design review updated.” The description asks the reader to confirm the delivery scope before Friday.

Group content by its job
Illustrative layout changes

If you only have a UI image, reconstruct a layered draft and inspect the layout relationships you still need to build. See the Dayline reconstruction and editing example.

Details and settings

We want the text to take the space beside a compact action. Longer content should make the row taller. Group the two text layers in a vertical container, then place that container and the button in a horizontal one. Use Shift+A to add auto layout to the relevant selection and check the flow.

These containers have different responsibilities. The inner one arranges two text blocks; the outer one arranges the content area and action. A single horizontal container would treat the title and description as separate objects in the same row.

02Choose sizing for this row

ObjectWidthHeightReason in this example
Notification rowFixed at 400px for the exerciseHugGive content a width boundary while allowing a taller row
Text containerFillHugUse the remaining width and hold both text blocks
Title and descriptionAvailable text-area widthGrow with the contentAllow wrapping rather than reserve one line
Action containerHugContent plus vertical paddingKeep a short action compact; review longer labels
Choose sizing for this row
Illustrative layout changes
Details and settings

Give the row 16px padding on each side and a 12px gap. If the button currently occupies 88px, the text receives 268px: 400 minus 32, 12, and 88. At a row width of 320px, the same assumptions leave 188px.

This is a space calculation, not a prediction of line count. Font, size, wording, and text settings still affect wrapping.

03Check text wrapping and height together

Replace the title with “Design review updated: please confirm the mobile and desktop delivery scope.” In our intended layout, it wraps within the text area, the description follows it, and the notification grows taller.

Check text wrapping and height together
Illustrative layout changes
Details and settings

If the title clips, check the text box and text container heights. If the row stays too short, inspect the outer container next. A hugging outer frame cannot remove a fixed text-box restriction inside it. Also distinguish changing a text box's width from scaling its font.

Figma: Adjust text dimensions and resizing

Truncation is a content decision. Here, delivery scope affects what the user must confirm, so we choose to display it. A one-line summary would need a deliberate way to reach the full information.

04Change the action label

Replace View with View change history. Hug lets the action grow with its content while the text area takes the remaining width.

Change the action label
Illustrative layout changes
Details and settings

A long action may still make the row unsuitable. Try moving it below the content when the text becomes too narrow, then compare the reading order. Repeatedly shrinking the font to preserve one row avoids a decision that the designer needs to make.

After typing a width directly into the button's dimension field, inspect its sizing again: Figma switches that axis to Fixed. A small visual adjustment can change how later labels behave.

05Inspect the parent and axis when an option seems wrong

Fill requires a child inside an auto layout parent. A top-level frame has no such parent to fill. Select the intended child and inspect its container before searching for another control.

Inspect the parent and axis when an option seems wrong
Illustrative layout changes
Details and settings

On the same axis, a hugging parent and filling child create a sizing dependency. Figma adjusts the parent's sizing mode in this case. Our example gives the outer row an explicit width before asking the text area to fill it.

Figma: Sizing rules and parent-child relationships

If an object no longer participates in the surrounding arrangement, check Ignore auto layout. Locate the object that left the normal flow before removing auto layout from the entire row.

06Recheck after placing rows in a list

Once a vertical list supplies the width, each notification can fill horizontally and hug vertically. On a duplicate, change the list from 400px to 320px, lengthen the title, lengthen the action, remove the description, and add a row.

Recheck after placing rows in a list
Illustrative layout changes
Details and settings

Change one condition at a time and note which layer first clips or squeezes its content. A row that needs a different structure can use one; matching every row's arrangement is not the goal.

Developers still need to implement these relationships. Auto layout settings do not themselves provide responsive website code. Layers reconstructed from an image also need their hierarchy and sizing inspected before being treated as a finished auto layout component.

Sources and example notes

We checked Figma's documentation and read Pixso's tutorial and Steve Kinney's course. Their explanations of content changes informed the approach. The notification scenario, arithmetic, design choices, and review sequence are our own; their images and exercise files are not reused.

Pixso: Auto layout tutorial

Steve Kinney: Auto Layout

Both space calculations have been checked. The images and fixed-view loops use original concept art and HTML layout examples. The example has not been built or verified in Figma.