KB vs Pixels: How File Size and Image Size Relate
Pixels are the size of the picture; KB is the size of the file. They are linked, but detail and compression decide how.
Upload forms often give two numbers for the same photo: a size in pixels (or centimetres) and a size in KB. They measure different things, and mixing them up is the most common reason a photo is rejected.
Pixels are the picture, KB is the file
A pixel is one dot of colour. A photo of 413 × 531 pixels has 413 dots across and 531 down, about 219,000 in total. That number does not change when you save the photo in a different way.
KB measures how much space the saved file takes. An uncompressed photo needs 3 bytes per pixel, one each for red, green and blue, so 413 × 531 pixels would take about 658,000 bytes, roughly 640 KB. Nobody uploads that. Formats such as JPG compress the pixels, and the same photo might become 40 KB, 20 KB or 8 KB depending on how hard it is compressed.
What decides the KB
Three things, in this order:
- The number of pixels. Half the width and half the height leaves a quarter of the pixels, and the file shrinks by roughly the same share.
- How much detail the photo has. JPG stores smooth areas cheaply and busy areas expensively. A face against a plain wall compresses far better than a crowd in front of trees. Two photos with the same pixels can differ in size by a factor of three or more.
- The JPG quality setting. Lower quality discards more fine detail. Below a certain point the photo turns blocky, especially around edges and in smooth skin tones.
A useful rule of thumb is to think in bits per pixel: a good-quality JPG of an ordinary photo uses somewhere around one to a few bits per pixel. The KB pages on this site show measured examples for each size, such as the 20 KB page.
Why a 20 KB photo can have any dimensions
Because the KB limit says nothing about pixels. You can reach 20 KB with a large photo at very low quality or a smaller photo at good quality. The second almost always looks better on a form, which is why our compressor reduces the dimensions before it lets quality drop too far.
If a form gives both a KB limit and pixels, both must be met. Set the pixels first, then the KB: the tool does both in one step when you open “Also change dimensions”.
Which number does the form check?
Usually both, but in different ways:
- The KB limit is checked exactly, by counting bytes. A file one byte over is rejected.
- Pixel sizes are often written as “preferred” or “at least”. An exact match is safest. A larger image of the same shape is often accepted; a smaller one often is not.
- Centimetres cannot be checked from a file without a DPI. A form that says “3.5 × 4.5 cm” and checks the upload usually converts it to pixels at some DPI, or only checks the shape. See what DPI really means.
Quick reference
| Pixels | Total pixels | Typical use |
|---|---|---|
| 140 × 60 | 8,400 | Signature on bank recruitment forms |
| 200 × 230 | 46,000 | Photo on bank recruitment forms |
| 413 × 531 | 219,303 | 3.5 × 4.5 cm at 300 dpi |
| 600 × 600 | 360,000 | 2 × 2 inch at 300 dpi |
| 4000 × 3000 | 12,000,000 | A 12-megapixel phone photo |
A 12-megapixel phone photo has about 55 times as many pixels as a 3.5 × 4.5 cm photo at 300 dpi. That is why phone photos are several MB and form photos are tens of KB.