Skip to main content

Typography Scale Generator

Generate harmonious font sizes using mathematical ratios.
Export as CSS custom properties with optional line-height.

Live Preview

5xl
89.8px
5.610rem
The quick brown fox
4xl
67.3px
4.209rem
The quick brown fox
3xl
50.5px
3.157rem
The quick brown fox
2xl
37.9px
2.369rem
The quick brown fox
xl
28.4px
1.777rem
The quick brown fox
lg
21.3px
1.333rem
The quick brown fox
base
16.0px
1.000rem
The quick brown fox
sm
12.0px
0.750rem
The quick brown fox
xs
9.0px
0.563rem
The quick brown fox
16px
12px24px
6
110
2
05
:root {
  --text-5xl: 5.610rem;
  --text-4xl: 4.209rem;
  --text-3xl: 3.157rem;
  --text-2xl: 2.369rem;
  --text-xl: 1.777rem;
  --text-lg: 1.333rem;
  --text-base: 1.000rem;
  --text-sm: 0.750rem;
  --text-xs: 0.563rem;
}

About Typography Scales

What is a type scale?

A typography scale is a set of font sizes that follow a mathematical ratio. This creates visual harmony and consistency across your design, similar to musical scales.

Popular Ratios

Perfect Fourth (1.333) is great for web design. Golden Ratio (1.618) creates dramatic contrast. Major Second (1.125) is subtle and works well for dense content.

How to Use

Use larger sizes (xl, 2xl) for headings, base for body text, and smaller sizes (sm, xs) for captions and labels. The ratio ensures all sizes work together harmoniously.