Image tools7 min read

How to Compress Images Without Losing Too Much Quality

Reduce image file sizes while keeping the details that matter. The best settings depend on whether you are optimizing a photograph, screenshot, transparent logo, or a small thumbnail.

In brief

Resize the image to the dimensions it will actually be displayed at, choose an appropriate format, adjust quality gradually, and compare the exported file with the original at its real display size. No quality percentage is best for every image.

Lossy vs. lossless compression

Compression reduces the amount of data required to store an image. Lossless methods preserve the image data exactly, while lossy methods discard some information to achieve smaller files. The right choice depends on how the image will be used and whether fine detail or transparency must be preserved.

Choose a compression approach by image type
Image typeGood starting choiceInspect before publishing
PhotographsJPEG or lossy WebPSkin tones, gradients, texture, and block artifacts
Interface screenshots or diagramsPNG or carefully tuned WebPSmall text, thin lines, labels, and sharp edges
Transparent logoSVG when appropriate, otherwise PNG or lossless WebPTransparent edges, colours, and scaling
Small preview imageWebP or JPEGWhether important details remain readable at thumbnail size

Repeatedly saving a lossy image can compound compression artifacts. Keep the original editable file and export from it when possible, rather than repeatedly recompressing an already compressed JPEG.

Choose a format and starting settings

For photographs, a medium-to-high quality setting is a useful starting point, not a promise about the result. Move quality up or down while checking detail. For graphics with text, a slightly larger lossless file is often more useful than a tiny file with visibly damaged edges.

Practical starting points; always verify the exported image
Use caseTry firstWhy
Large website photographWebP or JPEG at medium-high qualityUsually balances visual detail and file size
Product or portfolio imageWebP/JPEG at a higher qualityFine details may be important to the viewer
Screenshot with small textPNG or high-quality WebPText and edges are sensitive to artifacts
Transparent icon or logoSVG or PNG; test WebP if suitablePreserve transparency and crisp outlines

Before changing quality, check image dimensions. A 4,000-pixel-wide photo used in a 700-pixel content column may carry more pixels than the page needs. Resizing to a sensible display dimension can reduce the file substantially without adding compression artifacts.

A step-by-step optimization workflow

  1. Keep a source copy. Save the original file somewhere safe so you can export again later.
  2. Resize first. Use the Image Resizer when the original dimensions are far larger than the rendered image. Do not upscale a small image just to reach a large target.
  3. Choose a format. Use the format comparison guide to decide between JPEG, PNG, WebP, AVIF, or SVG.
  4. Adjust compression. Open the Image Compressor and lower quality gradually for photos. For text-heavy assets, begin with a lossless option or a higher quality setting.
  5. Compare at actual size. Inspect both images at the size visitors will see, as well as at 100% zoom for fine defects.
  6. Check output details. Confirm dimensions, file type, transparency, orientation, and whether the file opens in your target software.
  7. Use the optimized copy. Update the website or document with the exported file, then check the published page on a phone and desktop.

Our Image to WebP Converter can help with format conversion, but converting formats does not automatically mean the file becomes smaller. Test the actual output and choose the version that best meets the quality and compatibility requirements.

Measure the file-size reduction

Compare file sizes in the same unit. For example, a 1.2 MB image reduced to 360 KB saves roughly 70% when using decimal units (1,200 KB to 360 KB). The calculation is:

Percent reduction((Original size − New size) ÷ Original size) × 100

A smaller file is only a successful optimization if it still communicates the same information. Do not judge solely by the compression percentage: compare text, edge sharpness, colour gradients, transparency, and any subject details that matter for the page.

Publishing checklist

  • Use realistic image dimensions for the layout.
  • Keep a source copy of the original.
  • Use descriptive filenames and meaningful alternative text for informative images.
  • Set image width and height in markup where possible to reserve layout space and help prevent layout shifts.
  • Use decorative images with empty alt text when appropriate, rather than repeating nearby text.
  • Check the final image at mobile sizes and on the browsers your audience uses.
  • Do not publish a quality setting as a universal rule; document the setting that worked for the specific asset.

Frequently asked questions

What is the best quality setting for web images?

There is no universal best setting. Start in the medium-to-high range for photographs and adjust while checking the exported file. Text-heavy graphics and transparent logos often need a different format or a lossless option.

Does converting a JPEG to WebP always make it smaller?

No. The result depends on the source file, dimensions, compression settings, and encoder. Compare the actual file size and visible quality after conversion.

How does browser-based image compression work?

A client-side tool can read the selected file in the browser, process pixels locally, and export a new image. Check the tool’s stated behavior and avoid using shared devices for confidential files.

Should I compress an image before resizing it?

Usually resize first when the source dimensions exceed the intended display size. Then choose the format and quality. Keep the original in case you need another export.

References and related tools

Use these resources to continue checking the details or to complete the task described in this guide.

This guide is intended for practical learning and should be checked against the requirements of your own workflow. To suggest a correction, visit our Contact page or review our Editorial Policy.