Resize an Image in cm and mm at the Right DPI

Resize an Image in cm and mm at the Right DPI

Centimetres and millimetres are lengths. A JPEG is a grid of pixels. DPI (dots per inch) is the missing link: how many of those pixels you intend to put in each inch of paper. Without DPI, “35×45 mm photo” is not a file size — it is a print instruction. FlashKit Tools’ image compressor lets you type width and height in px, mm, or cm and pick 72, 200, or 300 DPI. The work stays in this tab.

This page is the unit-and-DPI explainer. For the India digital upload (630×810 px) see India passport photo size. For PAN 20 KB / 10 KB see PAN photo and signature size and compress a signature to 10 KB.

Resize in mm or cm

35×45 mm at 300 DPI is 413×531. Fit, do not stretch. DPI is written only when you ask for mm/cm or a named-DPI preset.

Open Image Compressor

The conversion, written out

One inch is 25.4 mm (2.54 cm). So:

  • pixels = mm ÷ 25.4 × DPI
  • pixels = cm ÷ 2.54 × DPI

Worked examples the compressor uses (rounded to the nearest pixel):

Physical size DPI Pixels Typical use
35×45 mm 300 413×531 ICAO-style print box
35×45 mm 200 276×354 Lower-resolution print
2.5×3.5 cm 200 197×276 PAN photo (Protean)
4.5×2 cm 200 354×157 PAN signature (Protean)

630×810 is not 35×45 mm at 300 DPI. It is the digital pixel box on the Passport Seva ICAO PDF. If a studio or a printer asked for 35×45 mm, use millimetres and 300 DPI, not the 630×810 preset.

Why a unit switch used to break the page

A common bug in browser resizers is to keep the number and change only the label. 800×600 px becomes “800 cm”. At 300 DPI that is about 94,488×70,866 pixels. The canvas fails and the row says Failed with no reason. FlashKit Tools now converts the displayed numbers so the pixel size stays the same, and it refuses a side larger than 8,192 px with a clear error.

800×600 px at 300 DPI is 6.77×5.08 cm (67.7×50.8 mm). Switching back to pixels should return about 800×600, not a poster.

Fit versus crop

A 3000×4000 phone portrait does not match an 800×600 landscape box. Stretching it to 800×600 flattens the face. With Maintain aspect ratio the compressor fits the photo inside the box: 450×600, empty space is not invented — you simply get a shorter width. Centre-crop fills the box and throws away the sides; that is what form presets do, and what the extra tick does for a custom box. It is never implied by “fit”.

When the JPEG actually stores DPI

Many viewers ignore JFIF density. Some form checkers do not. FlashKit Tools writes density bytes only when you chose mm or cm, or a preset that names a DPI. Quality mode and target-size mode share that path. A 630×810 passport export is not quietly stamped 300 DPI.

Step-by-step in the tool

  1. Open Image Compressor and drop the photo.
  2. Enable Resize. Pick Passport print (35×45 mm, 300 DPI), or type 35 and 45, unit mm, DPI 300.
  3. Leave aspect ratio on unless you want a centre-crop.
  4. If a portal also caps file size, stay in Target Size and pick 50 KB or 100 KB. Dimensions stay 413×531; quality is searched inside that box.
  5. Download. Check the row: 413×531, and “within target” if you set a KB limit.

35×45 mm at 300 DPI

413×531 pixels, DPI written, no stretch unless you turn aspect ratio off.

Open Image Compressor

Related Tools