Image guide

How to compress images for a website or WhatsApp

A photo straight from a modern phone is often several megabytes and thousands of pixels wide. That's far more than a web page or a chat message needs. Oversized images make pages slow to load and use up your visitors' mobile data, and messaging apps shrink them anyway, sometimes more than you'd like.

Compressing an image means storing it in fewer bytes while keeping it looking the same. The two biggest levers are its dimensions (how many pixels it has) and its format and quality setting. This guide covers both, for a website and for WhatsApp.

Open Image CompressorFree · Runs in your browser · Nothing uploaded

Updated 4 min read

01Step by step

Compress an image in your browser

  1. Step 1: Resize it first, if it's for a website

    If the photo is much wider than it will appear on the page, reduce its dimensions with the Image Resizer & Converter. A photo shown at 1,200 pixels wide doesn't need to be 4,000 pixels wide.

  2. Step 2: Open Image Compressor

    Drop, paste or choose your image in the Image Compressor. It reads JPG, PNG, WebP, GIF, BMP and, in most modern browsers, AVIF.

  3. Step 3: Pick the format

    WebP is the default and usually the smallest for photos. Choose JPG where WebP isn't accepted, and PNG only for graphics that need to stay lossless, such as screenshots or logos with sharp edges.

  4. Step 4: Adjust the quality

    Lower the quality slider while you watch the before-and-after preview. Stop when you can see a difference, then nudge it back up a little. The tool shows exactly how many bytes you've saved.

  5. Step 5: Download

    Download the smaller image. Re-encoding also removes metadata such as camera details and GPS location, which is good for privacy.

Open Image CompressorFree · Runs in your browser · Nothing uploaded

02Websites

Images for a website

Large images are one of the most common reasons a page loads slowly. A few habits keep them in check:

  • Match the display size. Export each image at the largest width it's actually shown at, or about twice that if you want it pin-sharp on high-density (Retina) screens.
  • Use WebP for photos. It works in all current major browsers and is usually smaller than a JPG of similar quality. AVIF can be smaller still and also works in current browsers, but not every website builder or tool accepts it yet.
  • Keep PNG for graphics. Logos, icons and screenshots with flat colors and sharp text often look better as PNG. For logos, SVG is even better if you have it.
  • Don't compress twice. Each lossy save throws away a little more detail. Keep your original and always compress from that.
  • Your platform may resize too. Many website builders make their own smaller copies of your images. Uploading a sensibly sized image still saves storage and upload time, and gives them a better starting point.

03WhatsApp

Sending photos on WhatsApp

WhatsApp compresses photos when you send them, to save data. Its help center says HD quality photos are clearer than Standard quality ones, but use more data and take longer to send. You have a few options:

  • Send in HD. After choosing a photo, tap the HD icon at the top of the screen and pick HD quality before sending.
  • Make HD the default. Go to Settings > Storage and data > Media upload quality and choose HD quality.
  • Send it as a document. Attach the photo with Document instead of from your gallery. WhatsApp then sends it as a file rather than as a chat photo. Documents can be up to 2 GB, but they don't appear as a picture in the chat.
  • Compress it yourself. On a slow or metered connection, or when sending lots of photos, compressing them first with the Image Compressor lets you choose the quality instead of leaving it to the app.

04FAQ

Questions people ask

There isn't a single number. Export each image at the largest size it's shown at on the page, or about twice that for sharpness on high-density screens. For a full-width photo, that's often somewhere around 1,600 to 2,400 pixels wide.

Lossy formats such as JPG and WebP discard detail you're unlikely to notice. At sensible quality settings the difference is hard to see; push the quality too low and you'll see blur and blocky patches. The live preview helps you find the point where it still looks right.

PNG is lossless, so the quality slider can't discard any detail. For photos, switch the output to WebP or JPG for real savings.

No. The Image Compressor runs inside your browser tab. Your photos stay on your device and are gone when you close the tab.

Try it now

Ready? Open Image Compressor.

It's free, there's nothing to install, and your files stay on your device the whole time.

Open Image CompressorFree · Runs in your browser · Nothing uploaded

Keep reading

All guides

Related

Sources

Steps that involve other products were checked against these pages when this guide was updated. Menus and prices can change.