Why "quality 80" is not a file size
Every image compressor offers a quality slider, and the number on it tells you almost nothing about the file you will get. JPEG quality is not a ratio or a target. It selects a quantisation table, which decides how aggressively the encoder discards detail in each block of the image. How much smaller that makes the file depends entirely on what is in the picture.
A photograph of a clear sky compresses enormously, because neighbouring pixels are nearly identical and the encoder can describe large areas cheaply. A photograph of gravel, foliage or a crowd does not, because there is genuine detail in every block and quantisation has less to throw away. The same quality 80 can produce a 90 KB file from one and a 900 KB file from the other. This is why "compress to quality 80" is a setting and "get this under 100 KB" is a job, and why asking a person to guess the first in order to achieve the second is a bad interface.
So this tool does not ask. You state the size you need, and it searches for the quality that lands under it. Encode, measure the real byte count, adjust, repeat. It is a bisection over the quality axis: each attempt tells the search which half of the remaining range to keep, and a handful of encodes converges on the highest quality that still fits. The number of attempts is bounded, and the result is the actual encoded file rather than an estimate, because the only reliable way to know how big a JPEG is is to produce it.
Two things fall out of that design. The first is that resolution is part of the answer. Below a certain size, no quality setting will fit a 12 megapixel photograph into 20 KB while leaving it recognisable, and the honest move is to reduce the dimensions rather than destroy the detail. The second is that the search runs on your device. Every one of those trial encodes happens in your browser, which is why the file never needs to be uploaded, and why the tool can afford to try repeatedly: nobody is paying for the CPU by the second.
If you are choosing a format rather than a size: WebP typically lands 25 to 35 percent below JPEG at visually equivalent quality, and AVIF lower still, but both are slower to encode and JPEG remains the format that every government portal and recruitment site will definitely accept. When a form says "JPEG under 100 KB", it means it.