Custom Aspect Ratio Calculator
Any ratio you dream up - 7:5, 2.35:1, 19.5:9 - type the two sides and solve any partner dimension. The URL updates as you type so you can bookmark ?rw=7&rh=5&w=1400 and share an exact custom pair. Start with 16:9 below and edit the ratio to your custom values.
1920 × 1080
Exact ratio: 16:9 · CSS: aspect-ratio: 16 / 9 · padding-top fallback: 56.25%
How custom math works
height = width x rh / rw
width = height x rw / rh
// example 7:5 at 1400 wide - 1400x5/7 = 1000 tall
padding-top = rh/rw*100% // 5/7*100 = 71.43%
Fractions and decimals both work - enter 2.35 and 1 for 2.35:1 cinema, or 19.5 and 9 for tall phones. The tool simplifies the ratio and gives the CSS aspect-ratio: rw / rh for any custom pair.
Try a preset then tweak
Pick any preset button, then edit the Ratio W/H fields to your custom numbers - the solved dimensions update live. Copy the pair or the CSS snippet.
Related
- 16:9 calculator
- 21:9 ultrawide
- CSS aspect-ratio guide
- 16:9 vs 21:9
- What ratio is 1920x1080?
- Print at 300 DPI
/custom/?rw=7&rh=5&w=1400 and the recipient sees 1400x1000 prefilled.