Best Image Size for Website: What KB, Resolution and Format to Use in 2026
Complete guide to choosing the best image size for websites. Learn optimal KB file sizes, pixel dimensions, and formats for every type of web image.
Choosing the best image size for a website is one of the most impactful decisions you can make for page speed, user experience, and search engine rankings. Get it right and your pages load in under two seconds, images look crisp at every screen size, and Google rewards you with higher positions. Get it wrong and visitors leave, bandwidth bills climb, and your Core Web Vitals scores suffer.
Yet most websites still serve images that are far larger than they need to be. A 2019 image unsqueezed to a few megabytes when a 100 KB version would look identical on screen. A hero photo rendered at 4000 px wide when the viewport is rarely wider than 1920 px. A PNG logo used where SVG or WebP would be a fraction of the size. These everyday mistakes add up to slow sites and frustrated users.
This guide covers everything you need to know about image size for the web in 2026: target KB ranges for every use case, optimal pixel dimensions, format selection, and practical steps to compress your images to the ideal size. Whether you are building a blog, an e-commerce store, or a corporate website, the principles here will help you ship images that are fast, sharp, and ranking-friendly.
Why Image Size Matters for Website Performance
Images account for roughly 60 to 75 percent of a typical web page's total weight, according to HTTP Archive data. That makes them the single largest contributor to page load time on almost every site. If your images are oversized, nothing else — not code minification, not CDN configuration, not lazy loading — can fully compensate.
The performance impact of image size is measured directly by Google's Core Web Vitals, a set of metrics that influence search rankings. The most important of these for images is Largest Contentful Paint (LCP), which measures how long the largest visible element takes to render. On most pages, the LCP element is an image — typically a hero photo, a product shot, or a featured image. Every kilobyte you shave off that image directly improves your LCP score.
The relationship between image file size and LCP is straightforward. A 500 KB hero image on a 4G connection takes roughly one second just to download (not counting decode and render time). A 100 KB version of the same image downloads in under 200 milliseconds. Google recommends an LCP of 2.5 seconds or less. If your hero image is the bottleneck, reducing its size is the fastest path to passing the LCP threshold.
Beyond Core Web Vitals, oversized images hurt conversion rates. Walmart reported a 1 percent lift in revenue for every 100 ms of improvement in page speed. BBC found that they lost an additional 10 percent of users for every additional second of load time. For e-commerce sites, where product images are both numerous and critical, the case for getting image size right is even stronger.
And there is a ranking angle that goes beyond performance. Google has stated that page speed is a ranking signal for both desktop and mobile search. In competitive niches where every ranking point counts, a well-optimised image strategy can be the difference between page one and page two. This is especially true for image-heavy queries like recipe searches, product listings, and photo galleries.
The best image size for a website is not a single number. It depends on where the image appears, how large it is displayed, what format you use, and what your visitors are viewing on. The sections below break down the optimal targets for every common scenario.
Image File Size Recommendations by Use Case
The following table summarises recommended image file size targets for different types of web images. These are guidelines, not hard rules — you can often push slightly higher for high-end photography or slightly lower for decorative images where quality matters less.
| Image Type | Target KB | Recommended Resolution | Best Format |
|---|---|---|---|
| Hero image (full-width) | 100–200 KB | 1920 × 1080 px | WebP / JPEG |
| Thumbnail image | 10–30 KB | 150 × 150 px | WebP / JPEG |
| Blog body image | 40–80 KB | 800 × 600 px | WebP / JPEG |
| Product image (e-commerce) | 80–150 KB | 1200 × 1200 px | WebP / JPEG |
| Background image | 50–100 KB | 1920 × 1080 px | WebP / JPEG |
| Logo | 1–10 KB | As needed | SVG / PNG / WebP |
| Icon | 1–5 KB | 48 × 48 px or SVG | SVG / PNG |
| Infographic | 100–300 KB | 1200 px wide | PNG / WebP |
These targets assume a modern image format like WebP. If you are using legacy JPEG or PNG without optimisation, expect results to be 20 to 40 percent larger for the same visual quality. The format section below explains when each format makes sense.
Key Tip
Image Resolution Guidelines
Image resolution — the pixel dimensions of the file — is often confused with file size, but they are distinct. A 1920 × 1080 image at JPEG quality 90 might weigh 400 KB. The same image at quality 60 might weigh 80 KB. The resolution is the same; the file size changed because the compression aggressiveness changed.
That said, resolution has a direct impact on file size. Doubling the pixel dimensions quadruples the number of pixels, which roughly quadruples the base file size before compression even begins. So choosing the right resolution is a prerequisite for hitting your KB targets.
Hero Image Size
The hero image is typically the largest and most prominent image on a page. It appears at the top, often at full viewport width. For desktop displays up to 1920 px wide, the hero image should be exported at 1920 px wide. For smaller viewports, use responsive image techniques (the srcset attribute with multiple resolutions) so mobile users download a 640 px or 768 px version instead.
A well-optimised hero image should target 100–200 KB in file size. At 1920 × 1080 px in WebP format, quality 75–80 typically lands in this range. For JPEG, you may need quality 60–70 to reach the same target. If the hero contains text overlays or a gradient, consider PNG or a higher quality setting to avoid banding artefacts.
Thumbnail Image Size
Thumbnails appear in galleries, search results, related post grids, and product listing pages. They are small by design, so their resolution should match. A common thumbnail size is 150 × 150 px, though some layouts use 200 × 200 px or 300 × 300 px. Export thumbnails at exactly the display size — never scale a larger image down via CSS.
The target file size for a thumbnail is 10–30 KB. In WebP or JPEG at quality 70, a 150 × 150 px image compresses to roughly 8–15 KB. At 300 × 300 px, expect 20–40 KB. Thumbnails are so small that even at high quality they stay under 30 KB in most cases. The bigger risk is using a massive source image and letting the browser scale it — that wastes bandwidth and slows down the page needlessly.
Blog Body Image Size
Images embedded within blog content typically span the content width, which is usually 700–800 px on desktop and 100% width on mobile. Export blog images at 800 px wide for traditional layouts, or at 1200 px for full-width content sections. Upscale images beyond their capture resolution to fill these dimensions will degrade quality — always capture or export at natural resolution.
Blog body images should target 40–80 KB each. At 800 × 600 px in WebP quality 75, most photos land at 50–70 KB. For screenshots or diagrams with sharp text and edges, JPEG compression introduces visible artefacts. In those cases, use PNG or a high-quality WebP setting even if it means a slightly larger file — readability of text in images matters more than a few extra kilobytes.
Product Image Size
E-commerce product images need to be detailed enough for zoom functionality but lightweight enough for fast page loads. The standard approach is to use a primary image at 1200 × 1200 px (square format for grid consistency) and additional angles at the same resolution.
Target file size for product images is 80–150 KB. At 1200 × 1200 px in WebP quality 75, most product photos fall within this range. If your platform supports it, serve a lower-resolution version (600 × 600 px, 30–50 KB) for the listing page and load the full-resolution version only when the user clicks through to the product detail page. This pattern is called progressive image loading and it significantly improves listing page performance.
How to Compress Images to the Right Size
Knowing the target size is only half the battle. You also need a reliable workflow to actually produce images that hit those targets. Here is a step-by-step approach that works for any type of image.
Step 1: Resize to the Display Dimensions
Before you do anything else, resize your image to the exact pixel dimensions you will display it at. If your blog content area is 800 px wide, resize the image to 800 px wide — not 1200, not 2000, not the original camera resolution. Tools like Photoshop, GIMP, and most image editing software can do this. For batch resizing, tools like ImageMagick or Squoosh are excellent.
Step 2: Choose the Right Format
For photographs and complex gradients, use WebP if your audience uses modern browsers (over 97% of global users) or JPEG as a fallback. For graphics with flat colour, text, or sharp edges, use PNG or SVG. For maximum browser compatibility with near-JPEG file sizes, use JPEG at quality 70–80. For maximum size reduction, use AVIF, which typically beats WebP by 15–25% but has lower browser support.
Step 3: Compress to Your Target KB
This is where a tool like CompressImg.in comes in. Unlike generic compression tools that apply a fixed quality level and hope the output size is acceptable, CompressImg.in lets you specify an exact KB target. Upload your resized image, enter your target — say 80 KB for a blog body image — and the tool adjusts the compression quality to hit that target automatically. The entire process runs in your browser, so nothing is uploaded to a server.
Step 4: Verify Quality
Download the compressed image and compare it side by side with the original at 100% zoom. Look for artefacts around edges, text, and high-contrast areas. If quality is unacceptable, increase the target KB slightly and recompress. As a rule of thumb, quality 70–80 in WebP is visually lossless for most photographs. Below quality 50, artefacts become visible on most images.
Step 5: Serve with Responsive Images
Use the srcset and sizes attributes on your <img>tags to serve different resolutions for different viewports. For example, a hero image might have versions at 640 px, 1024 px, and 1920 px wide. A mobile user on a 375 px viewport downloads the 640 px version instead of the 1920 px version, saving over 70% in bandwidth. This alone can cut your total page weight in half.
Pro Tip
Common Mistakes to Avoid
Even experienced developers make image sizing errors that hurt performance. Here are the most common ones to watch out for.
- Serving unscaled images. The most frequent mistake. A 4000 × 3000 px camera photo served inside a 300 × 300 px card wastes a huge amount of bandwidth. Always resize to the display dimensions before uploading.
- Using JPEG for screenshots or graphics. JPEG compression creates visible artefacts around text and sharp edges. Screenshots, diagrams, and UI mockups should use PNG or WebP lossless, even if the file is slightly larger.
- Ignoring the format. Serving PNG photos and JPEG logos is common but wasteful. PNG photos are 2–5 times larger than equivalent JPEGs. JPEG logos look blurry and have visible artefacts. Learn which format suits which content type.
- Not using responsive images. Serving a 1920 px hero image to mobile users on a 375 px screen is wasteful. Mobile users pay for bandwidth and wait longer per kilobyte. Use
srcsetto give smaller devices smaller files. - Overcompressing. Going below quality 50 on JPEG or quality 60 on WebP introduces visible artefacts on most images. The small file size saving is not worth the drop in perceived quality, especially for hero and product images.
- Neglecting metadata. Camera-generated images often contain EXIF data, GPS coordinates, thumbnails, and colour profiles that can add 50–200 KB of unnecessary data. Strip metadata before serving images on the web.
Frequently Asked Questions
What is the best image size for a website in KB?
There is no single answer because it depends on the image's role. For hero images, target 100–200 KB. For blog body images, 40–80 KB. For thumbnails, 10–30 KB. For product images, 80–150 KB. These ranges balance visual quality with fast load times on both desktop and mobile connections. Always resize to the display dimensions before compressing to these targets.
What resolution should web images be?
Resolution should match the display size. For full-width hero images, use 1920 × 1080 px. For blog content, 800 px wide is standard. For thumbnails, 150 × 150 px or 300 × 300 px depending on the grid. For product images, 1200 × 1200 px allows for detailed zoom. Using higher resolutions than these adds file size without visible benefit on most screens.
What is the best image format for websites in 2026?
WebP is the best all-around format for photographs and complex images, offering excellent compression (25–35% smaller than JPEG at equivalent quality) with broad browser support (over 97% of global users). For logos, icons, and graphics, use SVG for vector art or PNG for raster graphics. AVIF offers even better compression than WebP but has lower browser support. JPEG remains a safe fallback for maximum compatibility.
Does image size affect Google rankings?
Yes. Page speed is a confirmed Google ranking signal, and image size is the dominant factor in page speed for most websites. Large images increase Largest Contentful Paint (LCP) time, which is a Core Web Vital that directly impacts rankings. Properly sized images also reduce Cumulative Layout Shift (CLS) when dimensions are set explicitly in HTML. Optimising image size is one of the most straightforward SEO improvements you can make.
How do I reduce image file size without losing quality?
The best approach is a combination of three steps: resize to the display dimensions, choose the right format (WebP for photos, SVG/PNG for graphics), and compress with a tool that lets you control the output size. CompressImg.in allows you to set an exact KB target and automatically adjusts quality to hit it. Start with quality 80 for photographs — it is visually lossless for most images while reducing file size by 60–80% compared to the original.
Conclusion
Choosing the best image size for a website is not complicated once you understand the principles. Every image needs to be sized to its display resolution, encoded in the right format, and compressed to a KB target that reflects its role on the page. Hero images at 100–200 KB, body images at 40–80 KB, thumbnails at 10–30 KB, product images at 80–150 KB — these ranges give you the quality you need at the speed your users expect.
Start by auditing your existing images. Look at your most visited pages and check the file size of every image in the page weight report. You will almost certainly find images that are 2x, 5x, or even 10x larger than they need to be. Resize them, convert them to WebP, and use CompressImg.in to compress them to the exact KB target that makes sense for their placement. Run a Lighthouse test before and after — you will see your LCP drop, your performance score climb, and your page move closer to AdSense approval and better Google rankings.
Ready to compress your images?
Use our free online tool to reduce any image to an exact KB target — instantly, privately, in your browser.
Try Free Image Compressor →