Skip to content
IndexRequest a UIAboutContact

Modular Type Scale

Pick a ratio and base size and see four heading sizes grow by the same multiplier each step.

Open alone ↗

AI prompt

PROMPT: PASTE INTO YOUR AI IMAGE OR VIDEO TOOL
Typographic specimen poster on a warm off-white background showing a modular type scale: four lines of the word Hierarchy in the same sans-serif at ratio 1.25 sizes of 16, 20, 25 and 31 pixels aligned to the left, each line labelled with its pixel size in small grey monospace text on the right, thin hairlines between lines, generous margins, flat, minimal. Variants: ratio 1.618 with much larger jumps. Negative: decorative fonts, mixed typefaces, shadows, gradients, text errors. Reduced motion: static poster.

About this pattern

Definition

A modular type scale multiplies a base font size by a fixed ratio to get each next size. Because every step relates to the same number, headings look deliberately related instead of picked one by one.

When to use it

  • Small ratios (1.2) feel calm and dense, suited to apps; large ratios (1.618) feel dramatic, suited to editorial pages.
  • Choose the body size first, usually 16px, then build upward.
  • Round to whole pixels in production, and cap the biggest step on small screens.

What the controls do

  • Four ratios and a Base size slider.

Motion & timing

  • Sizes update instantly; there is no animation.
  • Reduced motion: nothing to change.

Tips & variations

  • On mobile, drop one ratio step or use a smaller ratio so headings do not break lines.
  • Keep at least 4px difference between neighbouring steps.

Code of this live preview

HTML
<div class="bx"><div class="pre" id="pre" role="group" aria-label="Ratio"><button data-p="0" aria-pressed="false">Minor third 1.2</button><button data-p="1" aria-pressed="true">Major third 1.25</button><button data-p="2" aria-pressed="false">Fourth 1.333</button><button data-p="3" aria-pressed="false">Golden 1.618</button></div><label class="rw">Base size <b id="bv">16px</b><input id="bs" type="range" min="12" max="20" value="16"></label><div class="ts" id="ts"></div></div>

Related patterns

Font Pairing & Hierarchy

↗
Font Pairing & HierarchyType Styles

Weight, Tracking & Leading

↗
Weight, Tracking & LeadingType Styles

Type Voices

↗
Type VoicesType Styles