To compress JPEG photos, re-encode them at a lower quality setting, once, from the original. At quality 80, the setting worth trusting, a typical phone photo comes back 60 to 80 percent smaller with no change you can see. A browser compressor does it in seconds, nothing to install, no signup, and it strips the GPS data out on the way.
That paragraph settles most JPEG questions. The format has been doing quiet work since 1992, though, and it repays a fuller look. I built and run the compressor on this site, and JPEGs are most of what comes through it, so every number on this page is measured off the real tool, not quoted from someone else. This is the hub for the format: what a JPEG is, what happens to your pixels when you hit save, what the quality slider actually changes, how small a JPEG really gets, and when the smart move is to leave JPEG behind.
Here is the map. Every row is a section below.
| If you want to | Go to |
|---|---|
| Understand what a JPEG is | What is a JPEG file |
| See what save does to your pixels | What happens when you save a JPEG |
| Pick a quality number with confidence | What does the quality slider change |
| Actually shrink one now | How to compress JPEG files in the browser |
| Know how small it can get | How small can a JPEG get |
| Decide JPEG vs WebP or AVIF | Should you keep JPEG or convert |
What is a JPEG file?
A JPEG is an image compressed with the standard published by the Joint Photographic Experts Group, the committee that issued it in 1992 (web.dev on the JPEG format). It is a lossy format, meaning it makes files small by throwing visual information away, and it is still the most widely used lossy still-image format there is (MDN image type guide). Every browser, phone, camera, and photo app opens one, a compatibility guarantee no newer format matches yet.
So what is JPEG in practical terms? A container for photographs, tuned for exactly that job and poor at most others.
The specs that matter
A JPEG stores 8 bits per color channel across three channels, which works out to 24-bit color and roughly 16.7 million possible colors. The MIME type is image/jpeg. The .jpg and .jpeg extensions are the same JPEG format with the same bytes inside; nothing changes between them except the file name. What the standard does not include is an alpha channel, so a JPEG cannot hold transparency, a limit that decides half of the "should this be a JPEG" questions on its own.
Where JPEG belongs, and where it does not
JPEG is built for continuous-tone images: photos, with their soft gradients and fine noise. It is the wrong tool for text, line art, charts, screenshots, and sharp-edged logos, which come out smeared and ringed at the block seams. The rule that falls out of that: photographs in JPEG, graphics in PNG.
What happens when you save a JPEG?
Saving a JPEG runs your pixels through six stages, and only two of them destroy information. Everything people notice about the format, the tiny files, the blocky artifacts when it goes wrong, the way a clear sky bands when you push too hard, comes out of those two stages.
Start with the raw material, because the scale of the job is easy to miss. A 12 megapixel photo is 12 million pixels at 3 bytes of color each, which is roughly 36 MB of uncompressed data. The 4.5 MB JPEG your phone actually writes has already squeezed that about 8 to 1 before you have touched a slider.
How does JPEG work? The six stages
Here is the JPEG compression pipeline, in order (Wikipedia on JPEG):
| Stage | What happens | Detail lost? |
|---|---|---|
| Color conversion | RGB becomes YCbCr, splitting brightness from color | No |
| Chroma subsampling | Color stored at lower resolution, usually 4:2:0 | Yes, color detail |
| Block splitting | Each channel divided into 8x8 pixel blocks | No |
| DCT | Each block rewritten as 64 frequency numbers | No |
| Quantization | Those numbers divided by a table and rounded | Yes, the main loss |
| Huffman coding | The rounded numbers packed losslessly | No |
Chroma subsampling and quantization: where the loss lives
The two lossy rows deserve plain English. Chroma subsampling works because your eye resolves brightness far more sharply than color, so JPEG keeps brightness at full resolution and stores color coarser. At the usual 4:2:0 setting the two color channels are halved in both directions, cutting them from two thirds of the file's data down to one third.
Quantization is the big one. The discrete cosine transform, or DCT, turns each 8x8 block into 64 numbers describing how much coarse and fine detail that block holds. Each number is divided by a value from a quantization table and rounded to the nearest integer, and the values for fine detail get divided by large numbers, so most of them round to zero. Long runs of zeros then pack down to almost nothing. That rounding is the loss. It is permanent, and it is exactly the dial the quality slider turns.
What does the quality slider change?
The quality number scales the quantization tables: a lower number means harsher rounding, more zeros, and a smaller file. It runs 0 to 100, it is not a percentage of anything, and it is not standardized, so quality 75 in one encoder does not mean what quality 75 means in another (web.dev). Treat it as a preference dial, not a measurement.
The useful range is narrow
The usable part of the scale is smaller than it looks. Google's web.dev team measured a case where quality 60 cut the file 79 percent, and found the differences across most of the scale imperceptible even in a side-by-side comparison (web.dev). In practice, 80 is the visually lossless default for photographs, 60 is the "smaller and still fine on a screen" setting, and below about 50 the compression starts to show its hand, first as blocking in smooth areas like skies, then as softness in skin and texture.
Why the same number looks different in two tools
Because the standard only defines what the quality value does to the math, not what any given number should look like, two encoders can read quality 70 differently. This is why a file exported at "70" from one app and "70" from another can differ in both size and appearance. Judge by the output size and a quick look, not by the slider position.
Why bother compressing a JPEG?
Three reasons, and they map to three different problems. On a website, smaller JPEGs load faster, and page speed is both a ranking input and the difference between a visitor who stays and one who leaves. In storage, a phone camera roll or a photo archive is almost entirely JPEG weight, so halving the files halves the bill. And for sharing, email services and upload forms enforce hard size caps that a raw 4.5 MB camera photo blows straight past.
Compression is not resizing
One distinction saves a lot of ruined images: compressing changes how the bytes are stored, resizing changes how many pixels exist. Dragging a corner handle in a document only changes the display size; the file underneath keeps every byte. When a photo is physically larger than anywhere it will be shown, resize first, then compress. When the dimensions are already right and only the bytes are too big, compression alone does it.
How to compress JPEG files in the browser
The fastest way to compress JPEG images is a browser compressor, because there is nothing to install and the defaults are already right. I use the one on this site here because I built it and can vouch for its numbers byte for byte.
- Open the JPG compressor and drop your photo on it. Up to 25 MB per image, up to 30 at once, no signup.
- Leave the quality at 80, the level the web treats as visually lossless for photographs.
- Read the after size on the result card. If you need it smaller, pull the quality slider down and watch the number fall until it fits. Re-running the same upload at a new quality or format never costs you anything.
- Download the result. The original on your device is untouched, and the copy you uploaded is deleted from our storage within the hour.
What happens to the file on the way through
Two useful things happen without you asking. EXIF data, the hidden metadata your camera writes into every file, including GPS coordinates and the exact moment you took the shot, is stripped by default. And the JPEG output is written progressive, so on a slow connection it renders in passes instead of loading top to bottom. Because the whole job runs in your browser and the uploaded copy is swept within the hour, nothing about the photo lingers on a server the way it does with upload-first tools.
How small can a JPEG get?
Smaller than most people expect, because the format is already doing heavy lifting before the quality slider enters the picture. Here is the same photo at three points in its life, measured on this tool in July 2026.
| Stage | Size | Share of raw |
|---|---|---|
| Uncompressed RGB | 36 MB | 100% |
| Camera JPEG | 4.5 MB | 12.5%, about 8 to 1 |
| Quality 80 | 0.9 MB | 2.5%, about 40 to 1 |
The camera already threw away five sixths of the raw data to reach 4.5 MB, and quality 80 takes another five sixths off that, landing near 0.9 MB with nothing you can see missing. That is the whole reason JPEG won: it is small enough, good enough, and openable everywhere.
When you need an exact number in KB
Some forms want a hard target, 200 KB for a passport photo, 100 KB for a listing, 50 KB for a government portal. That is the one case where you compress to a number instead of to a look, and quality alone rarely gets there from a full-size photo. The move is to cut the pixel dimensions first, then work the slider against the live after size. Reduce image file size in KB walks the exact-target workflow, and reduce JPEG size without wrecking it covers the artifact-diagnosis side when a previous compressor left a mess.
What is a progressive JPEG?
Progressive and baseline JPEGs use the identical lossy compression; the only difference is the order the data is stored and drawn. A baseline JPEG renders top to bottom, one clean strip at a time. A progressive JPEG stores its data in passes, so the whole image appears immediately at low detail and sharpens as the rest arrives. On a slow connection that is the difference between watching a photo load and staring at a blank box.
Progressive files also come out slightly smaller than baseline in most cases, at the cost of a little more decode work, and there is no quality tradeoff hiding in the choice because the pixels are the same either way. Our tool writes JPEG output as progressive by default for exactly those reasons.
What can a JPEG not do?
Two things: transparency and clean sharp edges. The JPEG standard has no alpha channel, so there is no such thing as a transparent JPEG, full stop. A logo saved as JPEG gets a solid background whether you wanted one or not, so anything that needs transparency belongs in PNG, WebP, or AVIF.
The second weakness is structural. That 8x8 block pipeline was tuned for the soft gradients of photographs, and it smears the hard edges in text, line art, charts, and interface screenshots, showing up as ringing and smudges along block seams right where a crisp edge used to be. PNG Explained covers that half of the split, including why PNG files run large and what to do about it.
The 8-bit ceiling
The 8 bits per channel limit matters at the edges too. It is plenty for a finished photo on a screen, but it is not enough headroom for heavy editing, which is why cameras shoot RAW and editors work in 16-bit formats before exporting a final JPEG.
Why does re-saving a JPEG make it worse?
Because every save re-runs the lossy stage on pixels that already went through it, and the losses stack. This is generation loss, and it works like photocopying a photocopy: each pass looks almost like the last, and ten passes in the damage is obvious (Cloudinary on JPEG generation loss).
Higher quality does not undo it
The counterintuitive part is that re-saving at a higher quality does not repair anything. Encode a quality 70 file at quality 95 and you get a larger file with more damage, not a restored one, because the encoder spends bytes faithfully preserving the compression artifacts that are already baked in.
What is actually safe
The reassuring part: opening, viewing, renaming, copying, and moving a JPEG are all harmless. Loss happens only when the image is re-encoded. So the fix is a workflow, not a tool. Keep the original, do your editing in a lossless format like PNG or TIFF, and export to JPEG once, as the last step. If you must re-save a JPEG, match the source quality rather than raising it.
Should you keep JPEG or convert to WebP or AVIF?
Convert what you publish, keep JPEG for what you send. WebP is typically 25 to 35 percent smaller than a JPEG of the same visual quality, and AVIF is often around 50 percent smaller, at the cost of slower encoding. The demo file on our home page is the concrete case: a 497 KB JPG comes out a 214 KB WebP at quality 80, which is 56.9 percent smaller with the same picture on screen. On a website, that saving lands on every visitor, every load.
| Format | Compression | Vs JPEG | Best for |
|---|---|---|---|
| JPEG | Lossy | baseline | Photos going anywhere old or unknown |
| PNG | Lossless | larger | Screenshots, logos, text, transparency |
| WebP | Both | 25 to 35% smaller | The modern default for the web |
| AVIF | Both | about 50% smaller | Maximum savings where support is known |
Where JPEG still wins
JPEG keeps two advantages. Compatibility is the first: email clients, older software, and picky upload portals all expect it, so a file headed into other people's hands is safest as a JPEG. Encoding speed is the second, which matters when you process thousands of images at once. The full head-to-head, including where AVIF's slow encode earns its keep, lives in WebP and AVIF, the modern formats. In the tool itself, format is an output dropdown, so trying WebP against your JPEG costs nothing but a glance at the after size.
JPG vs JPEG: are they the same?
They are the same format, byte for byte. The extension .jpg exists only because early Windows and DOS filenames were capped at three characters, so .jpeg got trimmed to .jpg, and the shorter spelling stuck. The MIME type is image/jpeg for both, every editor treats them interchangeably, and renaming one to the other changes nothing about the image. JPG vs JPEG: same thing, one letter has the full story, including the one case where letter case in the extension can trip up a strict server.
Every JPEG guide on this site
This page is the map; the guides below are the territory, grouped by the job in front of you.
Make a JPEG smaller:
- Compress a JPEG: methods that work is the full toolbox, browser, desktop, and command line.
- Reduce JPEG size without wrecking it is for when the last compressor left artifacts.
- Reduce image file size in KB hits exact limits like 50 KB for a form or 100 KB for a listing.
- Best JPEG compressors, compared puts the tools side by side, ours included.
Get something else into JPG:
- Convert any image to JPG covers the general case from any format.
- Convert PNG to JPG, and when not to explains the one conversion people regret.
- Convert RAW photos to JPEG gets camera files into something shareable.
- Convert HEIC iPhone photos to JPG fixes the format iPhones save by default.
The sibling pillars cover the neighboring formats: PNG Explained for lossless and transparency, and WebP and AVIF for the modern web formats that beat JPEG on size.