Image Size Calculator

Find dimensions for a target megapixel count, scale an image and see its raw memory.

Runs entirely in your browser. Nothing you type is uploaded.

About this tool

Work either way: give a ratio and a megapixel target to get dimensions, or give explicit sides. Both modes report the simplified ratio, the pixel count and the uncompressed RGB and RGBA memory, and a scaler converts to a target width, height or long edge.

Questions & answers

Why snap dimensions to a multiple?
Many image models work in latent blocks and want each side to be a multiple of 8, 16 or 64. Snapping avoids the model silently cropping or padding your request.
What is the raw memory figure?
The uncompressed pixel buffer: width × height × 3 bytes for RGB, or × 4 for RGBA. A PNG or JPEG file on disk is much smaller because it is compressed.
Does scaling to the long edge keep the ratio?
Yes. Whichever side is longer becomes the target and the other is scaled proportionally, so the composition is unchanged.

Related tools

Back to all Mini Tools