The best image size for a website is about twice the width the image is displayed at. As a guide, use 1920 to 2560 px wide for full-width hero images, 1200 to 1600 px for blog images, and 300 to 600 px for thumbnails. Save as WebP or compressed JPG, and keep most images under about 200 KB.
These are practical starting points, not official standards. Your theme and layout decide the real numbers, and the method below shows how to find them.
What is the best image size for a website?
Start with the space each image fills in your layout. Open the page in a desktop browser, right-click the image and choose Inspect. Developer tools show the rendered width in CSS pixels. Double that number so the image stays crisp on phones and laptops with high-density screens.
A quick reference for common image types:
- Full-width hero or banner: 1920 to 2560 px wide.
- Images inside a blog post or content column: 1200 to 1600 px wide.
- Product photos: 1000 to 2000 px on the longest side, larger if your shop zooms.
- Thumbnails and cards: 300 to 600 px wide.
- Logos and icons: SVG where possible, since it stays sharp at any size.
- Social sharing (Open Graph) image: 1200 x 630 px is the widely used size.
The most common mistake is uploading a 4000 px photo from a phone or camera into a 700 px column. The browser downloads every pixel, then throws most of them away. On a phone connection, that's seconds of waiting for nothing.
Pixel dimensions are all that matter on the web. The DPI number stored in a file is ignored by screens, so there's no need to set 72 or 300 DPI for a website. Our 300 DPI guide explains when that number does matter (printing).
Hero image size: how wide and how tall?
A hero image is the large banner at the top of a page. Because it stretches across the whole screen, it needs to be the widest image on your site.
- Width: 1920 px covers most desktop screens. Go up to 2560 px if you want it sharp on large high-density displays.
- Height: this depends on your design. Many heroes sit between 600 and 1000 px tall at desktop width.
- Shape: a wide crop such as 16:9 or 21:9 works on desktop. On phones, the same image is often cropped to the centre, so keep the subject in the middle.
- File size: try to stay under about 500 KB, and lower is better.
The hero is often the page's Largest Contentful Paint element, the moment Google uses to judge how fast your page appears. Google's web.dev guidance is to aim for an LCP of 2.5 seconds or less. A heavy hero is the usual reason a page misses it.
If text sits on top of the hero, a slightly darker or blurred image keeps it readable and compresses better, since smooth areas take fewer bytes than fine detail.
Blog image size for articles and featured images
For images inside a post, look at the width of your content column. Most blog themes use a column between 600 and 800 CSS pixels. Doubling that gives 1200 to 1600 px, which is the blog image size range above.
- Inline images in the article: 1200 px wide suits most themes. Use 1600 px if your column is wide.
- Featured image: check your theme's documentation. Many use a wide crop, and 1200 x 630 px doubles nicely as the social sharing image.
- Screenshots: keep them at their natural size if they're under the column width, so text doesn't blur from scaling up.
- File size: aim for 100 to 200 KB for photos. Screenshots saved as PNG can be larger, so try WebP for them.
Use one consistent shape for featured images across the blog. Mixed shapes make archive and category pages look uneven.
What file size should website images be?
There's no official limit, but rough targets keep pages fast:
- Most content images: under about 200 KB.
- Large hero images: under about 500 KB.
- Thumbnails: often 20 to 50 KB.
If KB and MB targets get confusing, our guide on how many KB are in a MB clears it up.
Correct dimensions do most of the work. Compression does the rest. A 1600 px photo saved as JPG at quality 75 to 85, or as WebP, usually lands in range. If an image is still heavy, use a compressor with a target size, such as ConvertorLab's Image Compressor. Compare the result with the original at full size before you publish.
Which format should you use?
- WebP for photos and graphics. Google says lossy WebP is 25 to 34% smaller than comparable JPEG, and lossless WebP 26% smaller than PNG. All current major browsers support it.
- SVG for logos, icons and simple illustrations.
- JPG as a fallback, or when your platform doesn't accept WebP.
- PNG only when you need lossless quality or transparency and can't use WebP.
Our explainer on what a WebP file is covers browser and app support. To convert existing files, use the image to WebP converter.
How to resize images for your website, step by step
- Keep your original high-resolution files in a separate folder. Never edit the only copy.
- Crop each image to the shape your layout uses, such as 16:9 for banners or 1:1 for cards.
- Resize to the target width. The Resize Image tool sets an exact width or longest side for a whole batch and can output WebP or JPG.
- Compress to your target file size, then check a few images at full size for blotches or banding.
- Rename files with short, descriptive, lowercase names, like
oak-dining-table.webp. - Upload, then add descriptive alt text in your CMS.
Many platforms resize and convert images on upload. Upload a sensibly sized file anyway. It saves storage and gives the platform a clean starting point.
Responsive images, lazy loading and checking your speed
How images load matters as much as their size. A few HTML habits do most of the work:
- Add
loading="lazy"to images further down the page, so the browser waits until the reader scrolls near them. - Don't lazy-load the hero. web.dev's guide to optimizing LCP says never to lazy-load the LCP image, and suggests
fetchpriority="high"for it instead. - Always set
widthandheighton images. The browser reserves the space, so text doesn't jump as the page loads. - For images shown at very different sizes on phones and desktops, offer several versions with
srcsetandsizes. MDN's responsive images guide walks through the syntax.
To find the worst offenders, run your page through PageSpeed Insights or the Lighthouse panel in Chrome's developer tools. They flag images larger than their display size, images that could use a modern format, and offscreen images that should load lazily. You can also open the Network tab, filter by Img and sort by size. Anything near the top that weighs more than a few hundred KB is worth resizing first.
Free tools that run in your browser
Frequently asked questions
What is the best image size for a website?
About twice the width the image is displayed at. That's typically 1920 to 2560 px for full-width heroes, 1200 to 1600 px for blog images and 300 to 600 px for thumbnails.
What size should a hero image be?
1920 px wide covers most screens, and 2560 px suits large high-density displays. Keep the file under about 500 KB and keep the subject near the centre for phone crops.
What is the best blog image size?
Double your content column width, which is usually 1200 to 1600 px. Aim for 100 to 200 KB per photo.
What file size should images be for a website?
There's no official limit, but under about 200 KB for most images and under about 500 KB for hero images keeps pages fast.
Does image DPI matter for websites?
No. Screens ignore the DPI value stored in a file. Only the pixel dimensions and the file size affect how the image looks and loads.
Is WebP better than JPG for websites?
Usually. Google says lossy WebP files are 25 to 34% smaller than comparable JPEGs, and all current major browsers support WebP.
