JPEG quality and the 8×8 blocks
Every JPEG carries, in its header, the rounding tables its encoder used. Those tables are the quality setting, written down — which is how a page can tell you a file's quality without guessing.
How JPEG throws information away
A JPEG encoder cuts the picture into 8×8 squares, describes each square as a sum of 64 patterns from smooth to fine, and then rounds each pattern's strength to a multiple of a step from its quantisation table. Fine patterns get large steps, because the eye misses them; smooth ones get small steps. The quality setting scales the whole table: at high quality the steps are small and the rounding is invisible, at low quality they are large and whole squares collapse to a flat colour.
Those collapsed squares are the blocks. They show most in smooth areas — sky, skin, walls — where the true picture changes gently and the rounded one changes in steps at every eighth pixel.


