Key Takeaways

  • Images are often the heaviest part of a web page. Resizing, compressing and using modern formats can shrink them dramatically with little visible change.
  • Upload images at the largest size they will actually display, not straight from the camera or phone.
  • WebP and AVIF are modern formats that are usually much smaller than JPEG and PNG at similar quality.
  • Lazy-load images further down the page, but never the main image at the top. That one should load right away.
  • Give every meaningful image short, descriptive alt text and a clear file name. It helps people using screen readers and helps Google understand the image.

Why Images Matter So Much

Photos sell. A real photo of your team, your work or your dishes builds more trust than any paragraph. That is why business websites are full of them.

The problem is size. A photo from a modern phone or camera is made for printing and zooming, not for a website. Uploaded as is, a single photo can weigh more than all the text, code and styles on the page combined.

Heavy images slow down every page they sit on, especially on phones with weaker connections. They are often the reason the main content takes too long to appear, which Google measures as Largest Contentful Paint, one of its Core Web Vitals. Our Core Web Vitals guide explains the three measures.

The good news: image optimization is one of the easiest speed wins. You do not need to give up quality. You need the right size, the right format and the right loading settings.

Step 1: Use the Right Size

The most common image mistake is uploading a photo far larger than it will ever display. If a photo appears 800 pixels wide on your page, but the file is 4,000 pixels wide, every visitor downloads many times more data than they can see.

How to find the right size

  • Full-width banners: often around 1,600 to 2,000 pixels wide is plenty for large screens.
  • Images inside the text column: usually around the width of the column, often 800 to 1,200 pixels.
  • Thumbnails and team photos: often a few hundred pixels.

These are rough guides. The exact number depends on your design. Ask your developer for the display sizes on your site, and resize to roughly twice the displayed width at most, so images stay sharp on high-resolution phone screens.

Resize before you upload

Most computers and phones can resize images with built-in tools. Free tools like Google's Squoosh, which runs in your browser, let you resize and compress in one step and compare the result side by side with the original.

Step 2: Compress

Compression shrinks the file by removing detail your eye does not notice. Done well, the difference is invisible on a website, and the file can be a fraction of its original size.

Lossy and lossless, in plain words

  • Lossy compression throws away some detail to make the file much smaller. It works well for photos.
  • Lossless compression keeps every detail and shrinks the file less. It suits logos, diagrams and screenshots with sharp edges and text.

For photos, try a quality setting somewhere in the middle and compare with the original at the size it will display. If you cannot see a difference, go a little lower. Stop when you start to notice blur or blotches.

Step 3: Choose a Modern Format

The format is the type of image file. The choice makes a big difference to file size.

  • JPEG: the classic photo format. Widely supported, decent compression.
  • PNG: good for logos, graphics and images that need transparency. Often large for photos.
  • WebP: a modern format supported by all major browsers. Usually much smaller than JPEG or PNG at similar quality, and it supports transparency.
  • AVIF: a newer format that often compresses even better than WebP. Supported by current versions of the major browsers.
  • SVG: not a photo format. It describes shapes with code, so it stays sharp at any size. Ideal for logos and icons.

Which should you use?

For photos, WebP is a safe, well-supported choice, and AVIF can squeeze files further. For logos and icons, SVG is usually best. Many websites serve modern formats automatically, with a fallback for any older browser that needs one. Your developer, your hosting, a content delivery network or an image plugin can handle the conversion.

Step 4: Serve the Right Size to Each Screen

A phone does not need the same image as a large desktop monitor. Responsive images let the browser pick the best size for each screen.

In the code, a single image can list several versions at different widths. The browser chooses the smallest one that will still look sharp on that device. A phone might download a version a few hundred pixels wide, while a large screen gets a bigger one.

Here is a simplified example of what that looks like in the page's code.

<img src="team-800.webp" srcset="team-400.webp 400w, team-800.webp 800w" alt="Our team">.

You do not need to write this yourself. WordPress and many website builders create several sizes of each uploaded image automatically. Just make sure the original you upload is large enough for the biggest size you need, and no larger.

Step 5: Lazy-Load Images Below the First Screen

Lazy loading means an image is only downloaded when the visitor scrolls near it. Images far down a long page do not slow down the first view at all.

Modern browsers support this with a simple setting in the image code: loading="lazy". Many platforms add it automatically.

Do not lazy-load the main image

This is a common and costly mistake. The large image at the top of the page, often a hero banner or main photo, is usually the content that Google's Largest Contentful Paint measures. If it is lazy-loaded, the browser waits before fetching it, and the main content appears later.

Google's web.dev guidance warns against lazy-loading images that appear in the first screen. Load the main image right away. Your developer can also mark it as high priority with a setting called fetchpriority="high", which tells the browser to fetch it early.

Help the browser find the main image early

Some sites load their main image in a way the browser cannot see until late, such as through a script or a background style. That delays it even when the file is small.

A plain image in the page's code, near the top, lets the browser discover and fetch it as early as possible. If your top image appears late in tests, ask your developer how it is loaded.

Step 6: Prevent Layout Shifts

Have you ever started reading a page, then had the text jump down as an image appeared above it? That is a layout shift, and Google measures it as Cumulative Layout Shift.

The fix is simple: tell the browser each image's width and height in the code, or reserve the space with styling. The browser then keeps room for the image before it arrives, and nothing jumps.

Getting the Top Image Right

The large image at the top of a page, often called the hero image, deserves special care. It is the first thing visitors see, and it is often the element that decides how fast the page feels.

  • Make it earn its place. A real photo of your work, team or location says more than an abstract stock image.
  • Size it carefully. Serve a smaller version to phones and a larger one to wide screens.
  • Compress it well. It is often the biggest file on the page.
  • Load it first. No lazy loading, and consider high priority.
  • Keep text out of it. Put the headline in real text on top of or next to the image.
  • Avoid sliders. One strong image loads faster than five rotating ones.

On phones, consider a different crop that keeps the subject visible in a narrow screen, rather than shrinking a wide photo until the subject is tiny.

Step 7: Write Useful Alt Text

Alt text, short for alternative text, is a description of an image stored in the page's code. Screen readers read it aloud for people who are blind or have low vision. Browsers show it if the image fails to load. Google uses it, along with the surrounding text, to understand what the image shows.

How to write good alt text

  • Describe what the image shows and why it matters on this page.
  • Keep it short, usually one sentence or less.
  • Be specific: "Technician replacing an outdoor AC unit on a home in Miramar" beats "AC repair."
  • Do not start with "image of" or "picture of." Screen readers already say it is an image.
  • Do not stuff keywords. Write for a person who cannot see the image.

When to leave alt text empty

Purely decorative images, like background patterns or divider lines, should have empty alt text, written as alt="", so screen readers skip them. The W3C's guidance on images includes a simple decision tree for choosing.

Images of text

Avoid putting important words, like offers or phone numbers, only inside an image. Screen readers, search engines and translation tools may not read them, and the text cannot resize on small screens. Put the words in real text, and use the image for the visual.

Step 8: Use Clear File Names

Google's image guidance notes that file names can give it clues about an image's subject. A name like IMG_4382.jpg says nothing. A name like kitchen-remodel-coral-gables.webp says a lot.

  • Use a few descriptive words, separated by hyphens.
  • Keep names short and readable.
  • Rename files before uploading, since changing names later can break links.

Image SEO Beyond Alt Text

Images can bring visitors from Google Images and help your pages rank, especially for visual services like remodeling, landscaping, food and beauty. Google's image guidance points to a few practical habits:

  • Put images near relevant text. Google uses the words around an image to understand it.
  • Use real, original photos. Your own project photos are unique. Stock photos appear on thousands of other sites.
  • Add captions where they help. A short caption, such as the project location and what was done, helps readers and context.
  • Use standard image code. Images loaded in unusual ways, like some background images set only through styling, may be harder for Google to find.
  • Keep important images crawlable. Do not block your image folders from search engines.

Photos for Your Google Business Profile

Many of the same habits apply to the photos you add to your Google Business Profile: real photos of your work, team and location, well lit and in focus, with no text stuffed into them.

Keep your original, full-quality files in a safe folder, and use optimized copies on your website. That way you always have the best version for any future use.

Logos and Icons

Logos and icons have different needs from photos. They have sharp edges, flat colors and often text, so photo-style compression can make them look fuzzy.

  • Use SVG for logos and icons when possible. It stays crisp at any size and is usually tiny.
  • If you must use a pixel format, use PNG or lossless WebP for sharp edges.
  • Keep your logo file small. It appears on every page.
  • Provide a square version of your logo for your favicon, the little icon in browser tabs, and for social sharing.

Galleries and Portfolios

Project galleries are powerful proof for contractors, designers, photographers and salons. They are also a common source of slow pages, because they can hold dozens of large images.

  • Show small thumbnails on the gallery page, and load the full-size image only when someone taps it.
  • Lazy-load thumbnails below the first screen.
  • Split very large galleries into categories or pages, such as kitchens, bathrooms and outdoor spaces.
  • Give each project a short description, location and alt text, not just a grid of pictures.

A gallery with captions and short project notes also gives Google far more to understand than a wall of unlabeled photos.

Stock Photos vs. Real Photos

Stock photos are quick and polished, but they come with downsides. Customers recognize them, they do not show your real team or work, and they appear on many other websites. Real photos, even taken on a good phone in good light, usually build more trust.

If you use stock images, choose ones that look natural, license them properly and optimize them like any other photo. Over time, replace them with real photos of your business.

Images for Different Kinds of Business

Restaurants and bakeries

Food photos sell, but menus should be real text, not photos of a printed menu. Optimize dish photos, lazy-load the gallery and keep the top image fast.

Contractors and home services

Before-and-after pairs are your best proof. Use the same angle for both shots, compress them well and caption each with the project type and area.

Medical, dental and professional offices

Team and office photos build comfort. Keep them warm and well lit, sized for their display spots, with alt text naming the person or room.

Real estate

Listings may have dozens of photos each. Thumbnails, lazy loading and modern formats are essential to keep listing pages usable on phones.

Online stores

Product photos need consistent sizes, a zoom view for detail and fast thumbnails in category pages. Automatic conversion to modern formats saves a great deal across a large catalog.

Background Videos and Animated Images

Background videos and animated GIFs are among the heaviest things you can put on a page. A short looping GIF can be larger than all your photos combined.

  • Replace background videos with a still image, and offer the video with a play button.
  • Convert animated GIFs to a short video file, which is usually far smaller.
  • Use a lightweight preview image for embedded videos, loading the player only when someone clicks.

A Simple Workflow for Every New Image

  1. Take or choose a real, well-lit photo.
  2. Crop it to the frame you need.
  3. Resize it to the largest size it will display, up to about double for sharp phone screens.
  4. Compress it, and convert it to WebP or AVIF if your site does not do so automatically.
  5. Give it a descriptive file name.
  6. Upload it, and add alt text that describes what it shows.
  7. Check the page on your phone.

Teach this routine to anyone who uploads images to your site. It takes a minute per photo and keeps the site fast for years.

Tools That Help, in Plain Words

  • Built-in editors: the photo apps on your computer and phone can crop and resize.
  • Squoosh: a free tool from Google that resizes, compresses and converts images in your browser, with a side-by-side preview.
  • Image plugins: on WordPress, plugins can compress and convert images automatically when you upload them.
  • Hosting and content delivery networks: many can resize, compress and serve modern formats automatically.
  • PageSpeed Insights: shows which images on a page are too large or could use a better format.

On WordPress, Wix and Other Platforms

WordPress

WordPress creates several sizes of each image you upload and can serve them responsively. An image optimization plugin, or your host, can compress uploads and convert them to WebP or AVIF automatically. Check that your theme uses the right sizes, and that the top image on each page is not lazy-loaded.

Wix, Squarespace and Shopify

Hosted platforms usually resize and convert images for you when they are displayed. That helps a lot, but uploading reasonable sizes still matters, and so does how many images you put on one page. Alt text and file names are still your job.

Custom-built sites

A developer can set up an automatic image pipeline that creates every size and format when an image is added. That is the most efficient setup, and it means nobody has to remember to optimize by hand.

Image Services and Content Delivery Networks

A content delivery network, or CDN, stores copies of your files on servers around the world and serves each visitor from a nearby location. Some CDNs and image services can also resize, compress and convert images on the fly, based on the visitor's device and browser.

For sites with many images, like stores, galleries and real estate listings, this can save a lot of manual work. Ask your host or developer whether your setup already includes image optimization, since many hosting plans do.

Accessibility Beyond Alt Text

Images affect accessibility in a few other ways too:

  • Text placed over a photo needs strong contrast, often with a dark overlay, so everyone can read it.
  • Videos need captions, and important information in a video should also appear as text.
  • Charts and infographics need a text summary of what they show.
  • Images that flash or move quickly can bother some visitors. Keep motion gentle and give a way to pause it.

Our website accessibility guide covers these in more depth.

Measure the Results

After optimizing, check that the work paid off:

  • Retest key pages in PageSpeed Insights and compare the page weight and Largest Contentful Paint with your earlier results.
  • Over the following weeks, watch the Core Web Vitals report in Search Console for improvement in real-visitor data.
  • Look at Search Console's performance data filtered to image search, if visual searches matter to your business.

Questions to Ask Your Developer

  1. Are our images converted to modern formats automatically?
  2. Does the site serve different image sizes to phones and computers?
  3. Is the main image on each page loaded right away, not lazy-loaded?
  4. Do our images have width and height set to prevent layout shifts?
  5. What size should we upload new photos at?

Common Image Mistakes

  • Uploading photos straight from the camera or phone.
  • Using PNG for photographs.
  • Lazy-loading the main image at the top of the page.
  • Missing width and height, causing the page to jump.
  • Huge homepage sliders loading many large images at once.
  • Alt text that is missing, generic or stuffed with keywords.
  • Important text, like phone numbers or offers, only inside images.
  • Background videos where a single image would do.

How to Check Your Own Site

  1. Run your homepage and a key service page through Google's PageSpeed Insights on mobile.
  2. Look at the image suggestions: oversized images, modern formats and images that delay the main content.
  3. Check whether your largest image at the top is lazy-loaded. If it is, change that first.
  4. In your media library, sort by file size and look at the biggest files.
  5. Fix the largest and most visible images first, then set up automatic optimization for new uploads.

Your Image Checklist

  • Every image is resized to its display size before upload.
  • Photos are compressed and served as WebP or AVIF where possible.
  • Logos and icons use SVG, or a sharp lossless format.
  • Phones receive smaller versions than large screens.
  • Images below the first screen are lazy-loaded.
  • The main image at the top loads right away.
  • Every image has width and height set, so nothing jumps.
  • Meaningful images have short, specific alt text, and decorative ones have empty alt text.
  • File names describe the image in a few words.
  • No important text lives only inside an image.
  • Galleries use thumbnails, and videos use lightweight previews.

A Quick Before-and-After

Say a landscaping company in Davie has a homepage with a five-photo slider, each photo uploaded straight from a camera, plus a gallery of forty full-size project photos. On a phone, the page takes a long time to show anything, and the gallery page is worse.

The team replaces the slider with one strong photo, resized and converted to WebP and loaded first. The gallery switches to small thumbnails that open full-size images on tap, with lazy loading below the first screen.

Every image gets a descriptive file name and alt text naming the project and city. The pages become far lighter, and the photos look just as good.

How We Help

Image work is a core part of our website speed optimization service. We resize and convert existing images, set up automatic optimization for new uploads, fix loading settings and add proper alt text. For the wider picture of how speed affects search, see our website speed guide, and run our free SEO audit to see where your pages stand.

Image Optimization FAQ

As large as they display, and no larger, up to about double the display width for sharp phone screens. Full-width banners are often around 1,600 to 2,000 pixels wide, and images in a text column are often 800 to 1,200 pixels. Ask your developer for your site's exact sizes.

For websites, usually yes. WebP files are typically much smaller than JPEG at similar quality, and all major browsers support WebP. AVIF can be smaller still. Many sites convert images to these formats automatically while keeping a fallback.

No. Lazy-load images further down the page, but load the main image at the top right away. Lazy-loading the top image delays the main content, which hurts how fast the page feels and Google's Largest Contentful Paint measure.

Alt text is a short description of an image stored in the page's code. Screen readers read it aloud for people who cannot see the image, browsers show it if the image fails to load and Google uses it to understand the image.

They help a little. Google's image guidance says file names can give clues about an image's subject. A name like kitchen-remodel-coral-gables tells Google more than IMG_4382. Rename files before uploading, using short descriptive words separated by hyphens.

Not if you compress sensibly. Compare the result with the original at the size it will display. If you cannot see a difference, the compression is fine. Stop lowering the quality when you start to notice blur or blotches.

Run PageSpeed Insights on your key pages, fix the largest and most visible images first, make sure the top image is not lazy-loaded, then set up automatic compression and modern-format conversion for every new upload.

Neither is ideal for photos on a modern website. JPEG is much smaller than PNG for photos, but WebP or AVIF are usually smaller still at similar quality. Keep PNG, or better SVG, for logos, icons and graphics with sharp edges and text.

Sources

More From the Blog