the IT Hustle
ToolsPricingBlogAbout

Spacing Scale Calculator

Generate a consistent spacing scale for your design system. Set a base unit and multiplier, see visual previews, and export as CSS custom properties or Tailwind configuration.

Spacing Scale Calculator

Generate consistent spacing scales for your design system. Set a base unit and multiplier, visualize the scale, and export as CSS or Tailwind config.

Scale Mode
Base Unit: 4px
Multiplier: 2
Steps: 10
Presets
Spacing Scale
0
0px0rem
1
4px0.25rem
2
8px0.5rem
3
16px1rem
4
32px2rem
5
64px4rem
6
128px8rem
7
256px16rem
8
512px32rem
9
1024px64rem
Visual Spacing Preview
4px
8px
16px
32px
64px
128px
256px
512px
Applied to a Card Layout
Card Title
Subtitle text

This card uses your spacing scale. Padding: 32px, gaps: 16px, small gaps: 4px.

PrimarySecondary
:root {
  --space-0: 0rem; /* 0px */
  --space-1: 0.25rem; /* 4px */
  --space-2: 0.5rem; /* 8px */
  --space-3: 1rem; /* 16px */
  --space-4: 2rem; /* 32px */
  --space-5: 4rem; /* 64px */
  --space-6: 8rem; /* 128px */
  --space-7: 16rem; /* 256px */
  --space-8: 32rem; /* 512px */
  --space-9: 64rem; /* 1024px */
}

How to Generate Spacing Scales

Create consistent spacing for design systems.

  1. 1
    Set baseEnter base unit (4px or 8px).
  2. 2
    ReviewSee steps with px/rem and visual bars.
  3. 3
    ExportCopy as CSS properties or Tailwind config.

Frequently Asked Questions

4px gives more granularity. 8px is simpler. Material uses 4px.

Consistent spacing creates visual rhythm. Without it, designs look unprofessional.

Related Tools

Type Scale CalculatorCSS Unit Converter