Changing an image's width and height simultaneously without adjusting for its aspect ratio stretches faces and warps logos. When your target frame has a different shape than your original photo, you have to choose between keeping the original proportions, cropping the edges (Cover), or padding the margins (Contain). You can test all three behaviors live in the Toolbase Image Resizer.

Choose settings for the dimensions you need

  • 150 × 200 px for an upload form: Select px, unlock the aspect ratio, and enter 150 for width and 200 for height. Preview the center crop. If it cuts off the subject, crop the photo manually before resizing, or use white margins if the form accepts them.
  • 1200 × 900 px from 4000 × 3000 px: Both frames are 4:3. Keep the ratio locked and enter 1200 as the width; the tool calculates a height of 900 px.
  • Under 100 KB at a required pixel size: Resize first. Check the exported file size, then use the Image Compressor if you need to reduce it further. Two photos with the same dimensions can take up different amounts of space.

How Aspect Ratio Locking Works

Aspect ratio is width divided by height. For example, 1920 × 1080 px is 16:9, and 1080 × 1080 px is 1:1. With Keep aspect ratio enabled, the Image Resizer calculates the height from your source image:

New Height = round(Original Height × (New Width / Original Width))

For example, entering a target width of 1200 px on a 4000 × 3000 px photo automatically outputs 1200 × 900 px with zero geometric distortion.

Cover vs. Contain vs. Stretch: Real 1920×1080 to 1080×1080 Example

When you uncheck Keep aspect ratio (or select a fixed-frame preset like 1080×1080 — Instagram (square)), the Fit method selector unlocks. Here is what happens to a widescreen 1920 × 1080 px image when resized to a 1080 × 1080 px square:

UI Fit Method CSS / Design Term What Happens to 1920×1080 → 1080×1080 Best Use Case
Crop to fill (center) Cover Scales height to 1080 px and trims 420 px from both the left and right edges. No blank bars. Avatars, social banners, thumbnails, passport & visa photos
Fit inside with white margins Contain Scales the full image to 1080 × 608 px and pads the top and bottom with 236 px of solid white (#FFFFFF). E-commerce product catalogs, logos, screenshots where no edge can be cut
Stretch Fill / Stretch Compresses the horizontal axis by 43.75% without cropping or padding. Subjects look narrow and distorted. Background gradients or abstract textures only

Converting Millimeters and Centimeters to Pixels (300 vs. 600 DPI)

Choose mm or cm to reveal the DPI selector (150, 300 or 600). Multiply the length in inches by the selected DPI and round to a whole pixel. One inch is 25.4 mm. This controls the pixel dimensions; it does not set a guaranteed DPI tag in the downloaded file. Check any separate metadata requirements with the receiving service.

  • 30 × 40 mm (3×4 cm ID preset): 354 × 472 px at 300 DPI (709 × 945 px at 600 DPI).
  • 35 × 45 mm (3.5×4.5 cm Visa / Schengen preset): 413 × 531 px at 300 DPI (827 × 1063 px at 600 DPI).
  • 50 × 50 mm (5×5 cm US visa preset): 591 × 591 px at 300 DPI (for strict 600 × 600 px US 2×2 inch portals, choose px mode and enter 600 × 600).

Practical Limitations to Keep in Mind

  • Center-only cropping in Cover mode: Crop to fill (center) always crops equally from opposite sides. If a person's face or a product sits near the top or side edge, crop it manually first in the Image Cropper.
  • White margin fill in Contain mode: Fit inside with white margins fills letterbox bars with pure white (#FFFFFF), even when exporting PNG or WebP.
  • Upscaling does not add detail: Enlarging a 300 × 300 px image to 1500 × 1500 px interpolates existing pixels on an HTML5 canvas; it cannot invent missing optical detail.
  • Batch and file size limits: You can resize up to 50 images per batch (up to 50 MB per file) locally in your browser. To shrink kilobyte weight further after resizing, use the Image Compressor.

Frequently Asked Questions

Why is the Fit method dropdown hidden when I open the Image Resizer?

By default, «Keep aspect ratio» is checked so you only need to type a new width and your image scales proportionally without cropping or padding. Uncheck «Keep aspect ratio» or pick a fixed-dimension preset (such as 1080×1080 or 3.5×4.5 cm) to reveal the Height field and the Fit method dropdown.

When should I use «Crop to fill (center)» vs. «Fit inside with white margins»?

Use «Crop to fill (center)» for profile pictures, YouTube thumbnails, and passport photos where white letterbox bars are not allowed. Use «Fit inside with white margins» for full-length product photos on e-commerce stores where cutting off the top or sides of the item would mislead buyers.

Does resizing an image reduce its file size in KB?

Downscaling pixel dimensions (for example, from 4000×3000 px to 1920×1440 px) significantly reduces file weight. However, re-encoding a JPG or WebP at 92% quality can occasionally increase byte size if the original image was heavily compressed; pass the result through the Image Compressor if you need a strict KB target.