Aspect Ratio Calculator.
Simplify width × height to a ratio, resize while keeping proportions and get the CSS aspect-ratio value.
Runs in your browserAbout Aspect Ratio Calculator
Aspect Ratio Calculator reduces any width and height to its simplest ratio and helps you resize without distortion. Enter 1920 by 1080 and it shows 16:9, the decimal 1.7778:1, the closest named standard, the megapixel count and the CSS declaration aspect-ratio: 16 / 9 together with the classic 56.25% padding-top value for older responsive embeds. Type a new width such as 1280 and the matching height of 720 appears; type a new height instead to get the width. You can also start from a ratio alone, like 4:3, 1.85:1 or 2.39, and the table lists common sizes from 320 to 7680 pixels at that ratio, marking which ones divide evenly and which had to be rounded. That flag matters for video encoding, where many codecs require even dimensions and a rounded height leaves a one-pixel black line. A frequent mistake is assuming every widescreen size is exactly 16:9. Laptop panels of 1440 by 900 are 16:10, cinema scopes are 2.39:1, and 2560 by 1080 ultrawide monitors are 64:27, sold as 21:9; the closest standard line reports how far off a size is. Another is scaling width and height by different factors when cropping thumbnails, which squashes the image; compute one side from the other instead. Decimal inputs work as well, so 1.85 by 1 simplifies to 37:20. Calculations run in your browser and nothing is uploaded.
How to Use
- Enter a width and height, or a ratio such as 16:9.
- Optionally enter a new width or height to calculate the other side.
- Copy the ratio, the CSS aspect-ratio value or a size from the table.
Frequently Asked Questions
How is the ratio simplified?
Width and height are divided by their greatest common divisor, so 1920 × 1080 becomes 16:9 and 2560 × 1080 becomes 64:27.
Is 21:9 really 21:9?
Usually not. 2560 × 1080 and 3440 × 1440 monitors are about 2.37:1 and 2.39:1. 21:9 is a marketing name for this range.
Should I use aspect-ratio or the padding-top trick in CSS?
The aspect-ratio property is supported by all current browsers. The padding-top percentage is only needed for very old browsers.
Is anything uploaded?
No. All calculations run in your browser.
Related Tools
Convert px, rem, em, pt and % with your root font size, or rewrite every px in a CSS block as rem.
Resize, crop and re-encode PNG, JPEG and WebP images to exact pixel sizes in your browser.
Convert between HEX, RGB, and HSL formats.
Estimate how long a file takes to transfer at a given speed, or the bandwidth needed to move it in time.
Convert numbers between bases (2–36).
Convert between Unix timestamps and dates.