Skip to content
Image Reshaper

← Guides

Updated 2026-09-15

How to Optimize Images for Website Speed

Image weight is usually the largest part of a page. Here is how to size, format, and compress images so pages load fast on mobile networks.

Images are usually the heaviest thing on a page

On a typical content website, images account for the majority of transferred bytes, frequently more than scripts, stylesheets, and fonts combined. That makes them the highest-leverage target for anyone trying to make a site faster, and it also makes them the easiest thing to get badly wrong, because an unoptimised image looks identical to an optimised one until you check the network panel.

Speed is not only a comfort issue. Slow pages lose visitors before the content appears, and page experience signals feed into how search engines evaluate a site. A page that takes eight seconds to become useful on a mobile connection is effectively invisible to a meaningful share of its potential audience.

Serve the size you actually display

The most common mistake is uploading camera originals and letting the browser scale them down with CSS. A 4000-pixel-wide photograph displayed in an 800-pixel column still transfers every one of those pixels; the browser downloads the whole file and then throws most of it away during rendering.

Work out the largest size each image is genuinely displayed at, double it if you want it to stay sharp on high-density screens, and export at that dimension. For a blog body image in a 700-pixel column, exporting at 1400 pixels is generous. Exporting at 4000 wastes roughly ninety percent of the bytes.

Reasonable export widths for common placements
PlacementDisplay widthExport width
Blog body image700 px1400 px
Full-width hero banner1200 px2000–2400 px
Card or grid thumbnail350 px700 px
Avatar or small icon80 px160 px
Logo in header180 px360 px or SVG

Choose the format deliberately

After dimensions, format is the next largest factor. Photographs should be WebP where you control the audience, or JPG where compatibility matters more than a few kilobytes. Flat graphics, screenshots with text, and anything needing transparency belong in PNG, or better still in SVG if the artwork is vector-based, since SVG scales infinitely at a tiny size.

The single biggest win on most sites is finding photographs that were saved as PNG and converting them. A photographic PNG is often five to ten times larger than an equivalent-looking WebP, and these files hide in content libraries for years because nobody checks.

Compress with intent, not by reflex

Once dimensions and format are right, compression is the finishing step rather than the whole strategy. Aiming for roughly sixty to seventy percent of the original file size usually produces no visible difference on a photograph viewed at normal size. Pushing much harder starts to show as banding in skies and mushy detail in foliage or hair.

Compress the correctly sized export, not the original. Compressing a 4000-pixel file to hit a small target forces brutal quality settings; resizing to 1400 pixels first and then compressing gently achieves a smaller file that looks considerably better.

  1. Resize the image to roughly twice its display width.
  2. Convert to WebP for photographs, or keep PNG for graphics with text or transparency.
  3. Compress to around sixty to seventy percent with the Image Compressor.
  4. Compare the result against the original at full size before publishing.
  5. Set explicit width and height attributes in your markup so the browser reserves space and the page does not jump as images load.

Things worth doing in your markup

File preparation only gets you part of the way. Add loading equals lazy to images below the initial viewport so the browser defers fetching them until the reader scrolls near. Leave your main hero image eager, because lazy-loading the first thing a visitor sees delays the metric that matters most.

Always declare width and height, or an aspect ratio in CSS. Without them the browser cannot reserve space, and content shifts downward as each image arrives, which is both irritating to read and actively penalised as a layout-stability problem. If your platform supports responsive image sets, provide several widths and let the browser pick, rather than sending a desktop-sized file to a phone.

Tools used in this guide

Continue reading