Golden Ratio Layout Calculator
Split widths, reverse a known column, or build a φ type ladder — with a live proportion bar and CSS output.
Input
φ = 1.6180 · exactClick a segment in the results to subdivide it. Three levels are allowed; each segment stays at least 1 px.
Proportions
1200 px totalClick a segment to split it again (depth 3 maximum).
| Segment | Rounded | Exact |
|---|---|---|
| Major | 741.64 px | 741.64 |
| Minor | 458.36 px | 458.36 |
| Total | 1200 px | — |
Forward ladder
| Step | Value |
|---|---|
| φ-3 | 283.28 px |
| φ-2 | 458.36 px |
| φ-1 | 741.64 px |
| φ0 | 1200 px |
| φ1 | 1941.64 px |
| φ2 | 3141.64 px |
| φ3 | 5083.28 px |
| φ4 | 8224.92 px |
CSS variables
:root {
--phi: 1.6180;
--w-major: 741.64px;
--w-minor: 458.36px;
--w-total: 1200px;
}Examples
Split a content column
1200 px → major 741.64 px, minor 458.36 pxThe major share is 1200 / φ; the minor is the remainder, so the pair adds back to 1200.
Reverse from a sidebar
minor 300 px → major 485.41 px, total 785.41 pxThe reverse mode solves total = minor × (φ + 1), useful when the sidebar width is fixed.
Type ladder
16 × φ⁰ = 16, ×φ¹ = 25.89, ×φ² = 41.89 pxA quick φ-based type ramp for headings and captions; no other scale ratio is assumed.
About this tool
Enter a width to get its φ split (major 61.8%, minor 38.2%). Reverse a known minor or major column, build a forward φ ladder or a type ramp from φ⁻³ to φ⁴, and choose exact, integer, even or grid rounding. The proportion bar can be subdivided up to three levels, and the rounded values are exported as CSS custom properties in your chosen unit. Rounding never breaks the invariant major + minor = total.
Everything runs locally in your browser — your inputs stay on your device and are never uploaded to a server.
What this tool does not do
- Processes only the inputs provided in this session without connecting to external accounts or background servers.
- Runs entirely in the current browser tab; nothing is synced across devices or backed up to a server.
How to use this tool
Enter total width or segment size
Input a container width (or known major/minor column) in px or rem.
Inspect φ splits and type ladder
View the 61.8% / 38.2% proportion bar, nested subdivisions, and modular type scale.
Copy CSS custom properties
Copy ready-to-use CSS variables or grid track definitions.
Use cases
Split a content column
The major share is 1200 / φ; the minor is the remainder, so the pair adds back to 1200.
Reverse from a sidebar
The reverse mode solves total = minor × (φ + 1), useful when the sidebar width is fixed.
Type ladder
A quick φ-based type ramp for headings and captions; no other scale ratio is assumed.
Common mistakes
Mistake:Should CSS grid and spacing values use exact decimals or whole pixels?
Fix:Fractional CSS units (fr, %, rem) handle exact φ ratios cleanly, while fixed pixel columns can be rounded to whole pixels with negligible visual change.
Mistake:How does a φ modular type scale work?
Fix:Multiplying a 16 px base size by powers of φ (16, 26, 42, 68 px) creates high-contrast display hierarchy suited for editorial hero headings.
Frequently asked questions
What is the golden ratio φ?
Phi (φ = (1 + √5) / 2 ≈ 1.618034) divides a total length into a major segment (≈ 61.8%) and minor segment (≈ 38.2%) such that total : major equals major : minor.
Should CSS grid and spacing values use exact decimals or whole pixels?
Fractional CSS units (fr, %, rem) handle exact φ ratios cleanly, while fixed pixel columns can be rounded to whole pixels with negligible visual change.
How does a φ modular type scale work?
Multiplying a 16 px base size by powers of φ (16, 26, 42, 68 px) creates high-contrast display hierarchy suited for editorial hero headings.
Can I compute the container width from a known sidebar width?
Yes. Reverse mode takes either the major or minor segment and solves for the matching partner dimension and combined container width.
Related tools
Aspect Ratio Calculator
Calculate dimensions and ratios for images and videos.
Border Radius Generator
Visually craft CSS border-radius values — including the advanced 8-value slash syntax for organic blob shapes — with a live preview and one-click copy.
Box Shadow Generator
Visual CSS box-shadow generator. Create beautiful shadows with live preview and copy the CSS code.
CSS :has() Selector Playground
Try the CSS :has() parent selector on live editable HTML and CSS, with ten patterns, dropped-rule detection and specificity notes.
CSS Button Generator
Design buttons with hover, active, focus-visible and disabled states — gradients, shadows, borders, icons — and copy clean CSS or Tailwind.
CSS Clip-Path Generator
Draw clip-path shapes visually: drag polygon points, tune circle/ellipse/inset presets, paste an SVG path and copy responsive CSS.