Skip to content
PictureToLink logoPictureToLink
Menu
Image Compression

How to Reduce Image File Size (Keep Quality)

How to reduce image file size in seven steps, starting with the one that saves most, with measured before and after sizes for each.

By Mudasir Ahsan (Founder) · · Updated · 11 min read
Facts checked against official sources on

On this page

To reduce image file size without visibly losing quality, resize the image to the largest size it will be shown at, save it in a suitable format (JPG or WebP for photos, PNG or WebP for graphics) at a moderate quality setting, and strip the metadata. Resizing does most of the work: in our tests, scaling our four sample photos to 1920 pixels wide at our default quality cut them by 62% to 95%. A free in-browser tool such as our image compressor does all of these steps in one go.

A photographer editing pictures on a laptop Photo: George Milton on Pexels

If you only change one thing, change the dimensions. The numbers below show why.

Why image files get so big

Three things decide the size of an image file.

Pixel count is the biggest. A modern phone photo can be 4000 pixels or more across. Every pixel has to be stored, so doubling the width and height roughly quadruples the data. That's why resizing beats every other setting below. The image size calculator shows the effect for any dimensions.

Format and compression come next. The same picture can be a few hundred kilobytes as a JPEG or several megabytes as a PNG. Formats compress in different ways, and some suit a given kind of image much better than others.

Then there's the picture itself. Busy scenes (foliage, gravel, crowds) and grainy low-light photos are harder to compress than clear skies and flat colors.

Camera metadata and color profiles add a little on top. Most images are far bigger than a screen needs, so you can usually shrink them a lot with no visible change. For typical sizes by format, and how many photos fit in 1 GB, see how many MB a photo is. To work it out for your own card or cloud plan, the photo storage calculator takes either a storage size or a photo count.

How much each step saves

We ran sample photos through our own upload pipeline (sharp/libvips) with different settings. The pipeline stores photos at up to 1920 px on the longest side, so every row below is already resized. These are measurements on our sample files and not promises for every image, but the pattern is consistent. Percentages are against the original file.

SettingPhoto A: 3024 × 2016 JPG, 1.65 MBPhoto B: 4032 × 2623 JPG, 390 KB
1920 px, JPEG quality 85575 KB (65.1% smaller)121 KB (69% smaller)
1920 px, JPEG quality 75374 KB (77.3% smaller)84 KB (78.4% smaller)
1920 px, JPEG quality 65271 KB (83.5% smaller)67 KB (82.9% smaller)
1920 px, WebP quality 75566 KB (65.6% smaller)55 KB (85.9% smaller)
1280 px, WebP quality 75180 KB (89% smaller)31 KB (92.1% smaller)
800 px, JPEG quality 7528 KB (98.3% smaller)22 KB (94.3% smaller)

Size did more than quality. Going from quality 85 to 65 at 1920 px made Photo A 52.9% smaller. Going from 1920 px to 800 px at quality 75 made it 92.6% smaller (both worked out from the byte counts). WebP helped one photo and not the other, which step 5 comes back to.

1. Resize to the size you need

This is the most effective step. A photo that will be viewed on a phone, in a chat window, in an email or in a blog post never needs the full resolution your camera captured.

Three sizes for the longest side cover most uses. At 1920 px a photo fills a typical laptop or desktop screen, which makes it a safe choice for pictures people may open full-screen. 1280 px is plenty for images inside articles, emails and forum posts. 800 px suits thumbnails, small inline images and product photos in narrow layouts.

Keep the original. Resizing down is permanent for that copy, and you may want the full-resolution version for printing or cropping later.

Resizing also eases the quality trade-off. At a given file size, a smaller image at quality 80 usually looks better than a huge image squeezed down to a very low quality setting, because the encoder can spend its bytes on fewer pixels. The exception is a picture people will zoom into, such as a product detail or a scanned document. There, keep more pixels and accept a bigger file.

2. Choose the right format

The wrong format can make a file many times larger than it needs to be.

For photos, use JPG or WebP. Saving a photo as PNG keeps every pixel of noise losslessly and produces a big file. Screenshots, logos and diagrams go the other way: PNG or WebP, because JPEG blurs text and sharp edges. For animations, pick animated WebP or a short video in place of GIF.

Our sample screenshot (1366 × 900) shows how much format matters for graphics. It was 2.38 MB as the original PNG, 730 KB re-saved as an optimized PNG with identical pixels, and 108 KB as WebP at quality 75. Our guide to image file formats explains when to use each one.

3. Lower quality a little

JPEG and WebP have a quality setting, usually on a scale of 0 to 100. Quality and size don't move together in a straight line. The top few points cost a lot of bytes and add little that anyone can see. In the table above, dropping from quality 75 to 65 at 1920 px made Photo A another 27.6% smaller and Photo B another 20.7% smaller (worked out from the byte counts).

Whether that's acceptable depends on the picture. A practical way to find out:

  1. Start at a quality around 80.
  2. Compare with the original at 100% zoom on the parts that matter. Watch smooth areas such as skies and skin for blockiness or banding.
  3. Lower the quality step by step until you notice a difference, then go back one step.

That routine doesn't suit screenshots of text, though. Low quality smears the letters long before a photo would look worse, so for those, change the format instead of the quality.

Lossy compression discards detail permanently, so always work from the original. Our explainer on lossy vs lossless compression covers why repeated re-saving degrades images.

4. Strip metadata

Photos from phones and cameras carry metadata: camera model, date and time, settings and often GPS location. Don't expect much of a saving here. It's usually small next to the image data, so the main reason to remove it is privacy, with a small size saving as a bonus.

Most compression tools remove metadata when they re-encode. Every upload to PictureToLink has all metadata discarded, and the image is rotated the right way up first so it doesn't end up sideways. To strip metadata and keep the file on your device, use our EXIF remover.

5. Use WebP or AVIF where supported

WebP and AVIF are newer formats that usually produce smaller files than JPEG and PNG. The MDN image format guide recommends preferring them for raster images on websites, with a JPEG or PNG fallback where older browsers matter.

"Usually" is doing real work in that sentence. In our tests, with both photos stored at 1920 px and quality 75, Photo B's WebP was 34.5% smaller than its JPEG, but Photo A's was 51.2% larger. Screenshots gained the most. So don't convert on faith. Save both and compare the sizes.

Where the file is going matters too. On your own website or blog, yes, ideally WebP or AVIF with a fallback. For sharing by link, WebP works in all current major browsers. For email attachments, online forms and printing, stick with JPG, because many apps and form validators still expect it.

6. Crop away what you don't need

Cropping removes pixels as well as distractions. Trimming empty sky, a cluttered border or the browser window around a screenshot can cut the file size noticeably, and the picture is clearer for it. Crop before you resize, so the remaining subject keeps as much detail as possible. It won't do much for a photo that's already framed tight on its subject, but it's free to try.

7. Reduce colors for simple graphics

Logos, icons, charts and interface screenshots often use only a handful of colors. Reducing a PNG to a limited color palette can make it much smaller while it still looks identical to most viewers. In our tests, palette reduction took the sample screenshot from 2.38 MB to 537 KB, compared with 730 KB for a lossless re-save. It's a lossy step, so check gradients and soft shadows for banding. PictureToLink's "Smallest file" setting does this for PNG uploads.

Online, Windows, Mac and phone options

Online, in any browser

Our image compressor runs entirely in your browser, so files aren't uploaded. Choose an output format (JPG, WebP or PNG), set a maximum width and a quality, and download the result. It can't squeeze much from a file that's already small and well compressed. If the result comes out the same size or bigger, keep your original instead. It works on phones as well as computers. If you need a specific size, for an application form for example, use the reduce image size in KB tool to aim for a target.

PictureToLink compressor: two photos marked Under 100 KB, each with a Download button

Two of our test photos on the compress to 100 KB page. The detailed one had to be made smaller to fit; the simpler one kept 1600 px.

Mac (Preview)

Apple's guide to resizing images in Preview describes choosing Tools > Adjust Size, selecting Resample image and entering smaller values for the size or resolution. Preview shows the resulting file size at the bottom of the window before you confirm. To adjust JPEG quality, choose File > Export, pick JPEG from the Format menu and use the quality option, as described in Apple's guide to converting image file types. Our Mac compression guide has more detail.

Windows

Paint can resize an image by percentage or pixels, and our guide to reducing image size in Paint goes through it. For format conversion and quality control, the in-browser compressor is usually quicker.

iPhone and Android

Phones don't make it obvious, but there are free ways to do it without installing anything. We have step-by-step guides for iPhone and Android.

Uploading to PictureToLink compresses images automatically. Photos are stored at up to 1920 px by default. Before you upload you can pick a smaller Resize option (1280 px or 800 px) and a Compression level, and optionally Convert to WebP.

Reducing many images at once

You don't have to process photos one by one. In the browser, the image compressor accepts several files at a time and applies the same format, width and quality to each. When you're sharing by link, the PictureToLink uploader takes up to 20 images at once with the same options, and Copy all gives you every link in one go. On a Mac, Apple's Preview guide notes that you can open several images in one window, select them all in the sidebar and choose Tools > Adjust Size to resize them together.

Mistakes that make files bigger

Some habits that feel safe work against you.

Saving at quality 100 is the common one. It produces much larger files than quality 90 with no visible benefit for normal viewing.

Converting a JPEG to PNG doesn't restore anything. The PNG keeps every JPEG artifact and is usually several times bigger.

Upscaling fails for a similar reason. Enlarging a small image adds pixels without adding detail, so the file grows and looks soft.

Re-compressing a compressed file is another. Each lossy save loses detail, and the size saving shrinks each time. Go back to the original.

JPEG is also a poor fit for screenshots of text. You need a high quality setting to keep text readable, which cancels out the saving. PNG or WebP is usually smaller and sharper.

How small is small enough?

There's no single right number. Aim for the smallest file that still looks right where it will be seen, and check any hard limits first.

Where the image is goingWhat to aim for
An online form with a stated limit (for example 50 KB or 200 KB)Just under the stated limit. Our 100 KB compressor and the other KB tools target common limits.
Email attachmentsKeep the total under your provider's limit, with room for encoding overhead. See our guide to email attachment size limits.
Chat apps and forumsResize to about 1280 to 1920 px. Size limits vary by platform.
Your own websiteAs small as possible without visible loss, sized for the space it fills. Every image adds to page load time.
PrintingDo not shrink. Keep the full-resolution original.

Some platforms don't state a limit at all. Reddit's help center publishes no table of image file-size limits or accepted formats, so a resized JPG or PNG is the safest thing to upload there. Our guide to posting images on Reddit has the steps.

If you've resized, chosen a sensible format and quality, and the file is still too big, the image is probably very detailed. Try a slightly smaller size or a lower quality and accept some loss, or send it as a link in place of a file. When you have to choose, lower the width before you lower the quality.

Image Compression

File Too Large to Upload? Fix It for Any Form

Getting 'file too large' when uploading a photo or signature to an online form? Check the limit, cut the KB size and dimensions, then retry.

· 8 min read
Image Compression

JPEG Artifacts: Why Photos Look Blocky

What JPEG artifacts are, why blocky edges and color banding appear after compression, which quality settings avoid them, and how to fix them.

· 9 min read

Related calculators