Space

Space is what makes a screen easy to read. It groups what belongs together, separates what doesn’t, and gives a page its pace. Thread spaces every layout from one scale, shared by Macy’s and Bloomingdale’s, for web and app.

The scale

Space sets the rhythm of every layout: the padding inside a container and the gaps between the things in it. Every value is a named step, so a layout is built from decisions the whole system shares, never from a number picked on the spot. Both houses use the same scale.

Anatomy

A product card, drawn to scale, with the three kinds of space that shape it.

123
  1. 1Inset is the padding inside a container, here td.space.xl, 20px on every side.
  2. 2Stack is the gap between items placed one above the other, here td.space.md, 12px under the image.
  3. 3Inline is the gap between items placed side by side, here td.space.xs, 8px between the buttons.

Steps

Thirteen steps, from none to 56px, used for padding and gaps alike. Small steps sit close together, for the fine adjustments inside a component; larger steps spread out, for the rhythm of a page.

  1. none0px
  2. 3xs4px
  3. 2xs6px
  4. xs8px
  5. sm10px
  6. md12px
  7. lg16px
  8. xl20px
  9. 2xl24px
  10. 3xl32px
  11. 4xl40px
  12. 5xl48px
  13. 6xl56px

3xs to md

Inside a component

Between an icon and its label, inside a chip, between the lines of a price.

lg to 2xl

Between components

Padding inside cards and sheets, gaps between controls and items in a list.

3xl to 6xl

Between sections

The rhythm of a page: between a module and the next, around a hero.

Density

Space forks by density. Compact is for dense screens, such as the tools our colleagues use in stores, and a component takes its values from the density of the container it sits in. Today Compact carries the same values as Comfortable; the mode is in place so screens can tighten later without a single component rebinding.

How to use

Each pair shows the practice and the mistake it guards against.

DoUse a space token for every padding and gap.
Don’tNudge a layout with a number that is not on the scale.
DoKeep related items closer together than unrelated ones.
Don’tSpace everything the same, so nothing reads as a group.

Tokens

Every step, as it is named in the Tokens library.

TokenComfortableCompact
td.space.none0px0px
td.space.3xs4px4px
td.space.2xs6px6px
td.space.xs8px8px
td.space.sm10px10px
td.space.md12px12px
td.space.lg16px16px
td.space.xl20px20px
td.space.2xl24px24px
td.space.3xl32px32px
td.space.4xl40px40px
td.space.5xl48px48px
td.space.6xl56px56px