What happens when you compress a JPEG

A JPEG is already a compressed image format — it throws away some detail to make the file smaller. When you compress a JPEG further, you are choosing how much more detail to discard. The trade-off is straightforward: smaller file size, lower image quality. Unlike compressing a Word document or a folder of files, you cannot compress a JPEG without losing something visible.

Most JPEG compression tools let you pick a quality setting, usually a number from 1 to 100. A setting of 80 to 85 often looks nearly identical to the original to the human eye, while dropping the file size by 30 to 50 percent. A setting of 60 to 70 shows visible softness and color banding, especially in photos with gradients or skin tones. Below 50, the image starts to look blocky and artificial.

If you need the image to look sharp — for a website header, a printed document, or a portfolio — test your chosen quality setting on a small section first. If you only need it readable on a phone or in an email, you can go lower.

Key Takeaways

  • JPEG compression always reduces image quality because the format discards detail; the lower the quality setting, the smaller the file but the blurrier the image.
  • Windows has a built-in Photos app that can resize and re-save JPEGs; Mac users can do the same in Preview without installing anything.
  • Online tools like TinyJPG and Compressor.io let you upload a JPEG and read a smaller version without installing software, though your image is temporarily on their server.
  • Batch tools like ImageMagick (command line) or XnConvert (graphical) can compress dozens of JPEGs at once with the same settings.
  • Always keep a copy of the original JPEG before compressing, because you cannot restore lost detail once you save over it.

Compressing a single JPEG on Windows

The simplest route on Windows is the Photos app, which comes built in. Right-click the JPEG file, select Open with, then choose Photos. Once the image opens, click the three dots in the top right corner and select Edit. You will see a menu with Crop, Rotate, and other options — none of these directly control compression quality.

Instead, use File > Save as (or press Ctrl+Shift+S). The save dialog will ask you where to put the file and what to name it. Before you click Save, look for a Quality or Compression slider — in Photos, this appears as a dropdown or a number field. Set it to 80 or 85 for a good balance, then save. The new file will be smaller than the original.

If you want more control, read XnConvert (free, from xnconvert.com). Open your JPEG in XnConvert, go to the Output tab, and set the JPEG quality to your chosen number. You can also resize the image here if you want to make it smaller in pixels as well as file size. Click Convert and choose where to save the result.

Compressing a single JPEG on Mac

Mac's Preview app handles JPEG compression without any extra software. Right-click the JPEG file and select Open With > Preview. Once the image opens, go to File > Export (or press Cmd+Shift+E). A dialog will appear asking you to name the file and choose a location.

At the bottom of the export dialog, you will see a Format dropdown — make sure it is set to JPEG. Below that is a Quality slider. Drag it to the left to make the file smaller (lower quality) or keep it to the right for higher quality. A setting around 0.75 to 0.80 on the slider is usually a good starting point. Click Save and the compressed JPEG will be written to your chosen location.

For batch compression of multiple JPEGs, use Automator (built into Mac). Open Automator, create a new Quick Action, search for Scale Images, and add it to your workflow. You can also add Change Type of Images to set the JPEG quality. Save the action with a name like "Compress JPEGs", then right-click any JPEG file and select it from the Quick Actions menu.

Using online tools to compress without installing software

TinyJPG (tinyjpg.com) and Compressor.io (compressor.io) are two widely used online compressors. Both work the same way: you drag a JPEG onto the page or click to upload it, the tool compresses it on their server, and you read the result. TinyJPG compresses up to 20 files per month free; Compressor.io has no monthly limit but shows ads.

The advantage of online tools is that you do not install anything. The disadvantage is that your image is temporarily stored on someone else's server. If the image contains sensitive information — medical records, financial documents, or anything you would not want on the internet — use a tool on your own computer instead.

Most online compressors do not let you choose a quality setting; they pick one automatically and aim for the smallest file size that still looks reasonable. If you need more control, use a desktop tool instead.

Compressing many JPEGs at once

If you have dozens or hundreds of JPEGs to compress with the same settings, batch processing saves time. ImageMagick is a command-line tool that runs on Windows, Mac, and Linux. To use it, you type commands into a terminal rather than clicking buttons. On Mac, install it with Homebrew (brew install imagemagick). On Windows, read the installer from imagemagick.org.

Once installed, open a terminal or command prompt, navigate to the folder containing your JPEGs, and type a command like this:

mogrify -quality 80 -strip *.jpg

This command compresses every JPEG in the folder to quality 80 and removes metadata (the -strip flag). The original files are overwritten, so make a backup first. If you want to keep the originals and create new compressed copies, use convert instead of mogrify.

If you prefer a graphical tool, XnConvert (mentioned earlier) also handles batch jobs. Open it, click Add Files and select all your JPEGs at once, set the quality in the Output tab, then click Convert. It will process all of them with the same settings.

Balancing file size and image quality

The right quality setting depends on how the image will be used. For a website, aim for 75 to 80 — most visitors will not see the difference, and the smaller file size means the page loads faster. For email, 70 to 75 is usually fine; email clients often compress images anyway. For printing or archiving, use 85 to 90 to preserve detail.

Test your chosen setting on a small sample before processing a whole batch. Open the original and the compressed version side by side on the screen you will actually use — a phone screen for mobile images, a monitor for web images. If you can see a difference you do not like, raise the quality setting and try again.

Keep in mind that JPEG compression is lossy, meaning you cannot undo it. Once you save a JPEG at quality 70, you cannot re-open it and save it at quality 90 to get back the lost detail. Always keep a copy of the original before compressing.

When to resize instead of just compressing

If a JPEG is 4000 pixels wide but you only need it to be 1200 pixels wide, resizing will reduce the file size more than compression alone. A 4000-pixel image at quality 80 might be 2 MB; the same image resized to 1200 pixels at quality 80 might be only 200 KB.

Most of the tools mentioned above can resize as well as compress. In XnConvert, go to the Transform tab and set a new width or height. In Preview on Mac, go to Tools > Adjust Size. On Windows Photos, use Crop to remove unwanted edges, though this does not change the pixel dimensions of the whole image.

If you are compressing for email or web use, resizing to the actual size you need is usually more effective than compression alone.

Frequently Asked Questions

Can I compress a JPEG multiple times to make it even smaller?

Technically yes, but each time you save a JPEG, you lose more detail. Compressing once at quality 70 and then again at quality 70 will not make it much smaller the second time, but the image will look worse. Compress once to your target quality and stop.

What is the difference between JPEG and PNG compression?

JPEG is lossy — it discards detail to shrink the file. PNG is lossless — it shrinks the file without losing detail, but PNG files are usually larger than JPEG files for photographs. Use JPEG for photos and PNG for images that need to stay sharp, like logos or screenshots.

Will compressing a JPEG make it blurry?

At quality 80 or above, most people will not notice blurriness. Below 70, you will start to see softness, especially in areas with fine detail or gradients. Test your chosen quality on a sample image first.

Do I need to pay for compression software?

No. Windows Photos, Mac Preview, XnConvert, TinyJPG, and Compressor.io are all free. ImageMagick is also free and open-source. You do not need to buy anything to compress JPEGs.

What happens to the metadata when I compress a JPEG?

Most compression tools keep metadata (camera settings, date taken, location) by default. If you want to remove it to make the file slightly smaller and protect privacy, use the -strip flag in ImageMagick or look for a Remove metadata option in your compression tool.