Prepare photos for your website
A photo straight from the camera can have several times the pixels your page displays, and every visitor downloads them all. The order that works: measure, resize, compress, check.
1. Find the display size
Look up the maximum width of the slot in your design. For high-density screens twice that is usually enough. A photo shown at 800 pixels does not need more than 1600.
2. Resize a copy
In Preview, show the Markup toolbar and click Adjust Size; keep proportional scaling on. For several, open them in one window, select them in the sidebar and use Tools > Adjust Size (Apple's guide).
In Terminal: sips -Z 2000 photo.jpg --out photo-web.jpg. Careful: -Z also enlarges a photo that was smaller, and the file can get heavier.
3. Pick a format
| Content | Sensible format |
|---|---|
| Photograph | JPEG or WebP |
| Screenshot with text, logo | PNG or lossless WebP |
| Image with transparency | PNG or WebP |
| Icon or vector drawing | SVG |
If you serve AVIF, compare its size and sharpness with the WebP version and provide a fallback for browsers that need one. Mozilla's image format guide.
With Rezide
Rezide is in testing and cannot be downloaded yet. The Web preset converts to WebP and caps the long side at 2000 pixels without enlarging smaller images. In automatic quality it looks for the smallest file that passes a visual quality threshold measured with SSIMULACRA2. Batch processes many photos and shows what each saved. If you need JPEG, duplicate the preset.
4. Check
- Look at skies, gradients and text at 100%.
- Make sure colours look the same in the browser.
- Upload the copy and open the page on a phone.
- Keep originals off the web.
What compression will not fix
A page can stay slow because of scripts, fonts or a slow server. In code, also declare width and height, lazy-load what sits further down and offer several sizes with srcset. If your platform already generates those, do not duplicate the work.
Common questions
WebP or JPEG?
WebP if your platform accepts it. If unsure, or the photo will travel by email, JPEG.
How heavy should each photo be?
There is no single figure. It depends on display size and content. Compare by eye and keep the smallest one that does not look compressed.
Is location data removed?
Rezide's Web preset removes location. With other tools, check.
Give the person building the page what they need
When a section uses a horizontal photo on desktop and a narrow version on mobile, export two crops if the second one would lose the subject. Put the width or use in the file name, for example cover-1600 and cover-mobile-800. Decide on framing with the actual layout open. A photo that looks complete in Finder may be cropped again when it fills a box on the page.
If the image has words that also appear as text on the page, export it without those words when you have the separate original. The browser can render its own text crisply and let the reader enlarge it. Apple's Preview cropping guide shows how to prepare a square or wide image without distorting it. Check the delivered image on a phone, where hard edges and overly fine details are easiest to miss in a desktop preview.