How to optimise images properly with size.

Serving the Right Image Size

I just spent three hours unravelling a “premium” client site that was essentially a graveyard of 5MB JPEGs masquerading as hero banners. It’s the same old story: someone buys a flashy theme, thinks they’re a designer, and then wonders why their PageSpeed score looks like a crime scene. Everyone wants to sell you a bloated plugin that promises to do the work for you, but if you want to learn how to optimise images properly, you have to stop looking for a magic button and start looking at the actual decisions being made at the pixel level.

I’m not here to give you a generic checklist of “best practices” that you could find in any mid-tier SEO manual. Instead, I’m going to show you the workflow I use to keep my builds lean, mean, and actually fast. We’re going to talk about real compression, sensible dimensions, and why your “high-res” obsession is actually killing your conversion rates. No fluff, no expensive automation nonsense—just the technical reality of how to handle assets without bloating your database.

Table of Contents

Audit the Decisions Behind Reducing Image File Size

Audit the Decisions Behind Reducing Image File Size.

When people talk about reducing image file size, they usually treat it like a magic button you press at the end of a project. That’s a mistake. I’ve inherited too many sites where the developer just slapped a compression plugin on a mess of 5MB JPEGs and called it a day. You can’t just compress your way out of bad decisions. You need to understand the fundamental trade-off between lossy vs lossless compression before you even touch a slider. If you’re stripping out too much data to chase a tiny file size, you’re just trading a slow site for a blurry one, and neither helps your bottom line.

I look at every asset through the lens of web performance optimization. It’s not just about making the file smaller; it’s about making it smarter. This means moving away from legacy formats and embracing next-gen image formats like WebP or AVIF. These aren’t just buzzwords; they are actual structural decisions that dictate how much bloat your browser has to chew through. If you aren’t auditing the source of your images—checking the dimensions, the color profiles, and the actual intent of the visual—you aren’t optimizing; you’re just guessing.

Mastering the Math of Lossy vs Lossless Compression

Mastering the Math of Lossy vs Lossless Compression

Most clients think “compression” is a magic button you press to make a file smaller, but they don’t realize there’s a mathematical trade-off happening under the hood. When I’m dealing with lossy vs lossless compression, I’m essentially choosing between surgical precision and aggressive efficiency. Lossless is great if you’re a purist—it keeps every single bit of data intact—but let’s be real: if you’re uploading a massive, unoptimized PNG to a hero section, you’re just sabotaging your own web performance optimization efforts. I’ve seen too many “designer” sites crawl to a halt because they refused to sacrifice a few invisible pixels for the sake of a decent load time.

In my workflow, I lean toward lossy compression for almost everything that isn’t a logo or a tiny icon. You have to be willing to let the algorithm discard the data the human eye won’t even miss. It’s about finding that sweet spot where the file size drops significantly without the image looking like a pixelated mess from 1998. If you aren’t auditing the artifacts left behind by your compression settings, you aren’t optimizing; you’re just guessing. Stop treating your assets like precious heirlooms and start treating them like functional web components.

Stop treating your media library like a junk drawer

  • Stop uploading the 5000px monster your photographer sent you. If your content container is only 1200px wide, serving a massive file is just lazy engineering. Resize the actual dimensions before you even touch a compression tool.
  • Use WebP, but don’t just blindly switch. I’ve inherited sites where the “automatic” conversion plugin broke every single hero image because it didn’t account for transparency. Test your fallbacks; don’t let a plugin make decisions for you.
  • Audit your SVG code. People think SVGs are “infinite” and “weightless,” but I’ve seen code-bloated vectors that carry more junk than a bloated page builder. Clean the paths and strip the metadata before you embed them.
  • Stop relying on “lazy loading” as a cure for bad habits. It’s a performance feature, not a license to upload unoptimized garbage. If your LCP (Largest Contentful Paint) is tanking, it’s probably because your “above the fold” images are being deferred like an afterthought.
  • Check your color profiles. I can’t tell you how many times I’ve seen a site’s color palette shift because someone uploaded an image in CMYK meant for print. Stick to sRGB. It’s not complicated, it’s just standard.

Stop outsourcing your site's speed

Stop outsourcing your site's speed.

At the end of the day, optimizing images isn’t some magical ritual you delegate to a plugin and forget about. It’s about understanding the math behind the compression and refusing to let a bloated, unoptimized file hijack your site’s performance. You’ve learned how to audit the decisions made during the resizing process, how to balance the trade-offs between lossy and lossless formats, and why blindly uploading a 5MB JPEG is basically a crime against your server. If you don’t control the pixels, you’re just letting a developer’s bad decisions—or your own laziness—dictate how your site feels to the user.

I’ve spent a decade cleaning up the messes left behind by people who thought “optimization” was just a checkbox in a settings menu. Don’t be that person. Treat your image assets with the same respect you give your typography or your code structure. When you take ownership of these small, granular details, you stop building sites that just “work” and start building sites that actually perform. Stop letting the bloat win; go back through your media library, audit your workflow, and make sure every single byte is earning its place on your page.

About Rasheeda Volkov

A theme is a set of decisions somebody else made. I read them before installing.

Author photo