← All articles

What JPEG Quality Was This Saved At? The File Already Knows

Someone sends you a photograph and asks whether it is good enough to print. You can see it is a bit soft and a bit blocky, but the question underneath is usually more specific: was this saved badly, or was it shot badly? Those have different fixes. One means asking for a better export. The other means reshooting.

The file answers the first half itself, and almost nobody looks.

The quality slider leaves a fingerprint

When a JPEG encoder saves a picture it divides the image into 8×8 blocks, converts each to frequencies, and then divides those frequencies by a table of numbers — the quantisation table. Big divisors throw away more detail and make a smaller file. Small divisors keep more and make a bigger one.

That table is not invented per file. Encoders start from a standard table published with the original JPEG specification and scale it by the quality setting you chose. Quality 90 scales it down (finer division, more kept), quality 30 scales it up (coarser division, more discarded).

The table is stored in the file, because the decoder needs it to reverse the division. So the scaling can be undone: compare the table in the file against the standard one, and the quality setting falls out.

Measured against files saved at known settings, on two different encoders:

Saved at Read back as
95 95
90 91
80 80
72 72
60 60
45 45
30 30
15 15

Not an estimate with a wide error bar. The setting is recoverable because it is, in effect, still written down.

Why the number is worth knowing

It separates two problems that look alike. Blocky edges at quality 88 mean the picture was already damaged before this save. The same blockiness at quality 35 means this save did it. One of those is worth chasing back to the source; the other you just re-export.

It tells you what another save will cost. JPEG is generational: every save re-divides and re-rounds, and the loss compounds. A file already at quality 45 has little left to give — editing and re-saving it a few more times will visibly fall apart. At 95 the next save costs almost nothing.

It catches a “high quality export” that isn’t. Export presets lie by omission. A file described as “full quality” that reads back as 62 was put through something, and the person who sent it may not know.

What the number does not tell you

It is not a quality score. Quality 95 on a badly-lit, out-of-focus photograph is still a badly-lit, out-of-focus photograph, stored expensively. The setting describes the encoder’s instructions, not the picture.

It is not the whole history. It describes the last save. A file saved at 40 and then re-saved at 95 reads as 95, and the damage from the first save is still there — baked into the pixels. That is why a measurement of the actual blocking in the image matters alongside it: the table says what was asked for, the pixels say what survived.

Different encoders scale the table differently. Two files at “quality 80” from different software are not bit-identical. The recovered number is the setting that was used, which is exactly what you want to know, but it is not a portable unit of goodness across tools.

The honest way to use it

Read the setting and measure the image, then compare the two:

  • High setting, visible blocking — the damage predates this file. Go back a generation.
  • Low setting, visible blocking — this save did it. Re-export from the source.
  • Low setting, clean image — flat or simple content compresses well; you got away with it, and you may be able to save space deliberately.
  • High setting, clean image — nothing to do.

That pairing is the whole point. A number from the header and a measurement from the pixels answer different questions, and put side by side they tell you where in the chain the problem entered.

What else the header is holding

The quantisation table is not the only thing a photograph carries that nobody reads. The same header usually holds the ISO it was shot at, the shutter speed, whether the file carries a rotation flag rather than being stored upright, which program last wrote it, and — often — the exact place it was taken.

Each of those answers a question a pixel measurement cannot. Noise in a photo is a fact; ISO 6400 is the reason. Softness is a fact; 1/15 of a second says it was movement rather than focus. And a location tag travels with the file to everyone you send it to, which is worth knowing before you publish it.


Check one image free: DiffALL’s image quality checker measures focus, noise, compression and clipping, marks where each problem is on your own picture, and reads the header back to you — the quality setting it was saved at, the camera settings behind the findings, and whether it is carrying a location. No sign-up.

Got the original as well? Compare the two images to see exactly what the export changed, pixel for pixel.

Stop hunting for differences by hand. DiffALL spots every change between any two files — automatically.

Compare your files — free